From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh-users@zsh.org
Subject: Re: (temporary) disable bracketed_paste
Date: Fri, 5 May 2017 13:13:03 -0700 [thread overview]
Message-ID: <170505131303.ZM30661@torch.brasslantern.com> (raw)
In-Reply-To: <59e27312-229e-a39f-7257-4b3a190b5c82@gmail.com>
On May 5, 7:55pm, Piotr Karbowski wrote:
}
} I'd like to know how to temporary disable zle_bracketed_paste. Best
} would be if I could disable it for a moment, and restore afterward.
[...]
} I tried to `unset zle_bracketed_paste` but it does work only on the root
} of .zshrc, if I wrap it within function, it does not do a thing.
zle_bracketed_paste is used when ZLE begins and when ZLE ends, because
it has to be in effect before any paste action occurs.
The value of $zle_bracketed_paste is an array containing the on/off
controls for the feature. So all you need is for example
print -nr ${zle_bracketed_paste[2]} >/dev/tty # Toggle off
{
#
# Do whatever it is you need to do
#
} always {
print -nr ${zle_bracketed_paste[1]} >/dev/tty # Toggle on
}
The "always" is just for sanity in case of early exit from whatever it
is you need to do.
next prev parent reply other threads:[~2017-05-05 20:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-05 17:55 Piotr Karbowski
2017-05-05 20:13 ` Bart Schaefer [this message]
2017-05-05 21:32 ` Piotr Karbowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=170505131303.ZM30661@torch.brasslantern.com \
--to=schaefer@brasslantern.com \
--cc=zsh-users@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).