zsh-workers
 help / color / mirror / code / Atom feed
From: Alexandre Duret-Lutz <duret_g@epita.fr>
To: zsh-workers@math.gatech.edu
Cc: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
Subject: Re: PATCH: _diff (new), _prcs (upgrade)
Date: 28 Jan 2000 16:04:23 +0100	[thread overview]
Message-ID: <mvbhffyw83s.fsf@phobos.lrde.epita.fr> (raw)
In-Reply-To: Sven Wischnowsky's message of "Fri, 28 Jan 2000 11:25:22 +0100 (MET)"

>>> "Sven" == Sven Wischnowsky <wischnow@informatik.hu-berlin.de> writes:

 Sven> Alexandre Duret-Lutz wrote:

[...]

 >> My opinion is: we should write $(XXX) if we are in the completion
 >> function for XXX, and $(command XXX) otherwise.

[...]

 Sven> But then a hackishly written function may still break everything (if
 Sven> you have a function for diff that actually does something if invoked
 Sven> with zero or only one argument, for example).

Yes.  And since _call shall allow people to customize the completion system
for those cases, it's not a problem anyway.  

[...]

 Sven> So the style would only be used to get the command (including: how it
 Sven> should be invoked, i.e. with `command' or not) and any options the
 Sven> user wants to give to it. If the style is not set we use some standard 
 Sven> way, so we don't have to set up default styles for this.

This (your last sentence) assume that no option is used by default (like
the call to ps in _pids).  This seems restrictive (but I don't have an
example where options are needed by default, and where the user would want
to change them).

 >> ...
 >> 
 >> Another point about the $+functions[<name>] test: what if I am writting a
 >> completion function for a shell function? say I need to call it, how do I
 >> do?

 Sven> Good point. Also testing $+commands and $+builtins might help here,
 Sven> but could still be wrong. Hm, I just wanted to make this cleverer but
 Sven> since the style would allow one to override it anyway, we should
 Sven> probably just call it without any pre-command modifier in the default
 Sven> case. Or let _call accept options like -c and -b to say that the
 Sven> default should use `command' or `builtin'. 

Given I am writting a _call in a completion function, how do I decide
whether I must use -[bc] or not?  We ne a rule here, that should be used
consistently in the completion system (see the first paragraph for what I
suggest). 

And if a rule is chosen, _call can apply it, and therefore -[bc] parameters
may not be needed anymore.

[...]

-- 
Alexandre Duret-Lutz


  reply	other threads:[~2000-01-28 15:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-01-28 10:25 Sven Wischnowsky
2000-01-28 15:04 ` Alexandre Duret-Lutz [this message]
  -- strict thread matches above, loose matches on Subject: below --
2000-01-31  9:09 Sven Wischnowsky
2000-01-28 15:11 Sven Wischnowsky
2000-01-28 16:24 ` Alexandre Duret-Lutz
2000-01-28  8:26 Sven Wischnowsky
2000-01-28  9:49 ` Alexandre Duret-Lutz
2000-01-27 16:08 Sven Wischnowsky
2000-01-27 17:21 ` Alexandre Duret-Lutz
2000-01-29  8:49 ` Alexandre Duret-Lutz
2000-01-27 14:52 Alexandre Duret-Lutz

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=mvbhffyw83s.fsf@phobos.lrde.epita.fr \
    --to=duret_g@epita.fr \
    --cc=wischnow@informatik.hu-berlin.de \
    --cc=zsh-workers@math.gatech.edu \
    /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).