From: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
To: zsh-workers@math.gatech.edu
Subject: PATH: was Re: [Q] user-defined completion
Date: Tue, 23 Jun 1998 15:02:18 +0200 (MET DST) [thread overview]
Message-ID: <199806231302.PAA11307@beta.informatik.hu-berlin.de> (raw)
In-Reply-To: Didier Verna's message of 23 Jun 1998 13:39:58 +0200
Didier Verna wrote:
>
> Sven Guckes <guckes@math.fu-berlin.de> writes:
>
> > Quoting Didier Verna (verna@inf.enst.fr): > I'd like to write a function for
> > special command line completion, but that is > aware of the program whose
> > command line we're completing. After reading the > doc, I see that
> > user-defined functions get 2 arguments: pre and postfix. Is there a way to
> > make such functions aware of the program name ? Any ideas ?
>
> > Are talking about "completion control" with "compctl"?
>
> Possibly, yes.
>
>
> > "man zshcompctl"!
>
> That's what I meant by saying "after reading the doc". But it seems
> that the answer is no. So, in case I'm missing something, or I'm just blind,
> I would have liked to know if somebody knows a way to achieve this.
>
Here is a patch for the Docs that makes `read' be mentioned at the
description for the `-K' option.
Bye
Sven
*** Doc/Zsh/compctl.yo.old Tue Jun 23 14:57:59 1998
--- Doc/Zsh/compctl.yo Tue Jun 23 15:00:12 1998
***************
*** 255,260 ****
--- 255,262 ----
passed two arguments: the prefix and the suffix of the word on which
completion is to be attempted, in other words those characters before
the cursor position, and those from the cursor position onwards. The
+ whole command line can be accessed with the tt(-c) and tt(-l) flags
+ of the tt(read) builtin. The
function should set the variable tt(reply) to an array containing
the completions (one completion per element); note that tt(reply)
should not be made local to the function. From such a function the
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
reply other threads:[~1998-06-23 13:07 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=199806231302.PAA11307@beta.informatik.hu-berlin.de \
--to=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).