emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Default setting for sh-maybe-here-document-mode


From: Stefan Monnier
Subject: Re: Default setting for sh-maybe-here-document-mode
Date: Fri, 20 Feb 2015 08:58:01 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> I was wondering why is `sh-electric-here-document-mode` activated by
> default for new documents in `sh-mode`?

IIRC I turned it into a minor mode and made it "enabled by default"
because the corresponding functionality was active by default before
(i.e. I just tried to preserve the previous behavior).

> I was under the impression that in most cases, this kind of commands,
> inserting text beyond what the user types, without requiring anything
> besides text input, are disabled by default.

We don't really have a clear policy on this.  I generally tend to prefer
keeping those things disabled, indeed, but OTOH electric-indent-mode is
now enabled by default (which is a pretty major counter example).

> And why is it so hard to disable it once you find out where the annoying
> behavior comes from?

Hmm... indeed, maybe it should be a global minor mode?

> (Just see how many articles deal with this specific
> issue; and having changed the name of the mode in 24.3 doesn't help)

I haven't noticed this, no.  Neither on gnu.emacs.help nor on stackoverflow.

> I understand that changing defaults is sensible, but in this case, wouldn't
> it be worth it? In my opinion, the only people who may appreciate this
> setting are people who know how to use C-q to work around it, and these
> people will know how to reactivate it.

It should (supposedly) be very rare that it triggers by accident.

If you have some sample scenarios where it triggers when it's undesired,
maybe we can fine-tune it to avoid those,


        Stefan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]