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

Re: How to capture the tab completion result?



Again: that's exactly what I needed.
Tnx a lot.
Mario


On Tue, May 28, 2013 at 10:25 AM, Bart Schaefer
<schaefer@xxxxxxxxxxxxxxxx>wrote:

> On Mon, May 27, 2013 at 9:45 AM, Mario Signorino
> <mario.signorino@xxxxxxxxxxx> wrote:
> >
> > zstyle ":completion:*:descriptions" format
> "\033[H<DESCRIPTION>%d</DESCRIPTION>"
> >
> > Is it also possible to enable the interpretation of backslash escapes?
>
> Just use the $'...' notation to embed a literal escape in the style:
>
> zstyle ":completion:*:descriptions" format
> $'\033[H<DESCRIPTION>%d</DESCRIPTION>'
>
> It's sort of a matter of personal preference whether to write
> $'\033'"[H..." (concatenate two sets of quotes) or just wrap the whole
> thing in $'...' like I did.  Concatenating the double quotes makes it
> easier to reference variables, etc., but you can't use $'...' inside
> double quotes.
>


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