Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: completions for su and implicit fg/bg
- X-seq: zsh-workers 7198
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: PATCH: completions for su and implicit fg/bg
- Date: Mon, 19 Jul 1999 15:58:11 +0200 (MET DST)
- In-reply-to: Sven Wischnowsky's message of Mon, 12 Jul 1999 12:39:15 +0200 (MET DST)
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
I wrote:
> I wrote:
>
> > This allows `compset -q' on unquoted words -- almost. There is a
> > problem when the match contains characters that have to be quoted. In
> > such cases the match should be quoted twice (`a b' should be inserted
> > as `a\\\ b'), but currently the completion code is far from being
> > prepared for such double-quoting and I'm seeing to much places where
> > changes are needed for a quick patch.
>
> I've been thinking some more about this... This can get pretty ugly
> when we have multiple calls to `compset -q' for the same word. In such
> cases we would have to keep track of the number of calls (the nesting
> level) and then quote the words put into the command line n times. Of
> course the results may become almost unreadable and it would require
> changes in several parts of the code.
I've now spent several days trying to get this right -- and am now
really fed up. My last solution almost worked but still had problems
with, e.g. zsh -c 'zsh -c "zsh -c echo\ <TAB>. Mainly due to the
somewhat weird backslash-in-quotes behavior. Also, I only had this for
inserting unambiguous matches (do_single()), and the stuff for
unambiguous prefixes is even harder.
So, I *will* some day try to fix this, but I don't think I'll be able
to do this this week and next week I'll be away.
I'll have to find a completely different way for this...
Bye
Sven
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author