Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Unset “zle_bracketed_paste” .zshrc
Andrew Reyes wrote on Fri, 17 Jan 2020 23:20 +00:00:
> The problem is:
> 1) zsh/zle's setup_() assigns the parameter, overwriting existing values
>
> 2) not possible to 'unset' the parameter before zsh/zle is loaded.
@Andrew thanks for the report. Let me spell out the symptoms for the list:
In zshrc, «typeset -a zle_bracketed_paste=('' '')» and «unset
zle_bracketed_paste» have no effect if done before zsh/zle has been
loaded, because of zsh/zle's setup_() unconditionally assigns to the
parameter, even if it already exists and has a non-null value.
I looked into this yesterday, and guarding the assignaparam() call with
a paramtab->getnode() != NULL fixes the case that the variable is
already set by the time zsh/zle is loaded (e.g., if it's set in zshrc).
However, I haven't been able to make «unset zle_bracketed_paste» have
any lasting effect if done before zsh/zle is loaded. Is that achievable?
Messages sorted by:
Reverse Date,
Date,
Thread,
Author