zsh-workers
 help / color / mirror / code / Atom feed
From: Frank Terbeck <ft@bewatermyfriend.org>
To: zsh-workers@sunsite.dk
Subject: Re: PATCH: Add CORRECT_NOCOMPSYS option
Date: Thu, 28 May 2009 21:03:38 +0200	[thread overview]
Message-ID: <20090528190338.GC3315@fsst.voodoo.lan> (raw)
In-Reply-To: <m3vdnlawz2.fsf@klanderman.net>

Greg Klanderman <gak@klanderman.net>:
> >>>>> Frank Terbeck <ft@bewatermyfriend.org> writes:
> 
> > The final goal for what?
> 
> Not completing all the stupid completion widget functions starting
> with "_" at a shell prompt where they are totally irrelevant.
[...]

Yes, that was my guess. Completion.

> > For completion (without looking at it in detail), I think what Greg
> > wants could be done with the _ignore completer.
> 
> > :
> 
> > So, when you're talking about a final goal, IMHO, CORRECT_IGNORE is
> > quite a reasonable solution.
> 
> Neither of these mechanisms do what I described.  If you allow
> substring completion, i.e.
> 
> | zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' '+ l:|=* r:|=*'
> 
> then even with the 'ignored-patterns' zstyle set to '_*', if you try
> to complete something which has no non-ignored matches, it will then
> fall back to not ignoring those patterns, and will complete to
> something that starts with "_" even when there was no "_" before you
> hit <tab>.  If you remove the _ignore completer, then you can never
> complete a function starting with "_".

Since I don't use matcher-lists, I cannot comment any further. Compsys
experts will have to take on that one. :)

> For CORRECT_IGNORE, just look back to Richard's original question in
> this thread - with that setting you can *never* complete something
> that matched the pattern, which is not what you want.

That's my point. CORRECT_IGNORE has *nothing* to do with completion.
It's about correction. That is precisely why I was asking about what
Richard meant by 'final goal', because the thread initially had
nothing to do with completion.

Final goal in completion - based on what you described - will have to
be solved within compsys.

Final goal in correction (for the problem I described), can be
achieved by what CORRECT_IGNORE provides. If someone wants more
control in _correction_ than that, that someone would probably have to
reimplement the correction code into a more flexible system (maybe
even function based - like compsys). But I doubt it would be worth it.

> Even with the 'matcher-list' setting for substring completion, file
> completion of files starting with '.' does work as I want.  Can
> someone point me to where that is handled?

Could a compsys guru shed some light on this? :)

Regards, Frank

-- 
In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
                                                  -- RFC 1925


  reply	other threads:[~2009-05-28 19:04 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-05  0:07 Frank Terbeck
2009-04-05  2:37 ` Bart Schaefer
2009-04-05 12:23   ` Frank Terbeck
2009-04-05 18:13   ` Peter Stephenson
2009-04-05 22:11     ` Bart Schaefer
2009-04-06  9:09       ` Peter Stephenson
2009-05-27 16:30         ` Richard Hartmann
2009-05-27 16:59           ` Peter Stephenson
2009-05-27 19:12             ` Greg Klanderman
2009-05-28  8:48               ` Richard Hartmann
2009-05-28  9:25                 ` Frank Terbeck
2009-05-28 18:44                   ` Greg Klanderman
2009-05-28 19:03                     ` Frank Terbeck [this message]
2009-05-28 19:35                     ` Peter Stephenson
2009-05-28 22:56                       ` Greg Klanderman
2009-05-29  8:32                         ` Peter Stephenson
2009-05-29 14:38                           ` Greg Klanderman
2009-05-29 14:49                             ` Peter Stephenson
2011-03-01 20:39                 ` PATCH: zstyle to control completion of functions/parameters beginning with underscore Greg Klanderman
2011-03-01 21:11                   ` Peter Stephenson
2011-03-01 22:07                     ` Greg Klanderman
2011-03-02  1:05                   ` Oliver Kiddle
2011-03-02 18:49                     ` Greg Klanderman
2011-03-02 23:30                       ` Bart Schaefer
2011-03-03 15:33                         ` Greg Klanderman
2011-03-03 16:11                           ` Greg Klanderman
2011-03-03 16:54                           ` Bart Schaefer
2011-03-06 20:07                             ` Greg Klanderman
2011-03-06 22:02                               ` Bart Schaefer
2011-03-08 15:13                                 ` Greg Klanderman
2011-03-09 18:41                                 ` Greg Klanderman
2011-03-10 15:54                                   ` Bart Schaefer
2011-03-10 16:44                                     ` Greg Klanderman
2011-03-10 17:10                                       ` Bart Schaefer
2011-03-10 18:01                                         ` Greg Klanderman
2011-03-11 17:01                                     ` Greg Klanderman
2011-03-03 16:58                           ` Oliver Kiddle
2011-03-02  1:13                   ` Richard Hartmann

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=20090528190338.GC3315@fsst.voodoo.lan \
    --to=ft@bewatermyfriend.org \
    --cc=zsh-workers@sunsite.dk \
    /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).