Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Unset “zle_bracketed_paste” .zshrc

On Thu, 2020-02-06 at 14:32 +0100, Mikael Magnusson wrote:
> On 2/6/20, Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx> wrote:
> > 
> > Well, it's an option.  It would result in the following interface:
> > to prevent $zle_bracketed_paste from being defined one will have to run
> > «unset zle_bracketed_paste» if zsh/zle has been loaded, or «zmodload -Fa
> > zsh/zle -p:zle_bracketed_paste» otherwise.
> I would assume that if someone knew to run that obscure zmodload
> command, they would know they could just do this instead,
> zmodload zsh/zle
> unset zle_bracketed_paste

No, this is entirely about autoload behaviour.  "zmodload -Fa" provides
selective autoload out of the box, which in principle fixes the issue
with no fundamentally new features, just appropriate module exports.

However, the main reason for doing this with zmodload would be to
provide consistency with different types of module feature, and there's
no real call for that as people are much more used to the parameter
interface.  So in practice adding behaviour to "unset" is probably
easier for everyone.

It would be neater to be more consistent about the way module features
are provided, just on the basis that if it's in a module it should use
the module interface, else why are we pretending it's a module at all
rather than building it into the shell?  But that can go way down a very
long list.


Messages sorted by: Reverse Date, Date, Thread, Author