Folding for bash scripts?

65 views
Skip to first unread message

Lois Bennett

unread,
Jul 24, 2019, 2:00:55 PM7/24/19
to BBEdit Talk
Hi,

I would really like folding and a function pull down for my bash scripts.  Is that possible?  Am I just missing something?

Thanks


The information in this e-mail is intended only for the person to whom it is
addressed. If you believe this e-mail was sent to you in error and the e-mail
contains patient information, please contact the Partners Compliance HelpLine at
http://www.partners.org/complianceline . If the e-mail was sent to you in error
but does not contain patient information, please contact the sender and properly
dispose of the e-mail.

TJ Luoma

unread,
Aug 21, 2019, 1:04:16 PM8/21/19
to BBEdit MailingList
On Wed, Jul 24, 2019 at 2:00 PM Lois Bennett <sa...@channing.harvard.edu> wrote:

> I would really like folding and a function pull down for my bash scripts. Is that possible? Am I
> just missing something?

I think this has come up before and the answer was "No" but I'm hoping
that either my memory is faulty or the answer has changed, because I
would really like to see this too.

Tj


--
TJ Luoma
TJ @ MacStories
Personal Website: luo.ma (aka RhymesWithDiploma.com)
Twitter: @tjluoma

TJ Luoma

unread,
Aug 21, 2019, 1:42:52 PM8/21/19
to BBEdit MailingList
On Wed, Aug 21, 2019 at 1:03 PM TJ Luoma <luo...@gmail.com> wrote:

> On Wed, Jul 24, 2019 at 2:00 PM Lois Bennett <sa...@channing.harvard.edu> wrote:
>>
>> I would really like folding and a function pull down for my bash scripts. Is that possible? Am I just missing something?
>
> I think this has come up before and the answer was "No" but I'm hoping that either my memory is
> faulty or the answer has changed, because I would really like to see this too.

Well, one of these things is true, because it _IS_ possible to do
code-folding in bash in BBEdit.

Select the text you want to fold and go to "View" » "Fold Selection".

By default there's no keyboard shortcut, although you can easily make
once yourself.

The only thing that is really missing is the little "indicators" in
the gutter which show you where a fold starts/stops.

Tj

Lois Bennett

unread,
Feb 10, 2020, 2:10:03 PM2/10/20
to BBEdit Talk
I had not responded to this because I had been working on python.  Now I am back to working with 500 line bash scripts again, and I must say that though, yes, you can fold manually like that. It is not very helpful when you are trying to write code. The little "indicators" in the gutter do more than tell you where the fold starts and stops. They allow you to fold and refold the section. To simply glance at what is in the bit you have hidden, you have to go through so many steps.  Unfolding is, of course, trivial, but the to hide it again requires reselecting and going back to the pull-down, etc. and if the section is more than a screen, it is just a nuisance.  I do feel quite neglected not having support for bash in this wonderful program.


Well, one of these things is true, because it _IS_ possible to do
code-folding in bash in BBEdit.

Select the text you want to fold and go to "View" » "Fold Selection".

By default there's no keyboard shortcut, although you can easily make
once yourself.

The only thing that is really missing is the little "indicators" in
the gutter which show you where a fold starts/stops.

Tj
Reply all
Reply to author
Forward
0 new messages