zsh-workers
 help / color / mirror / code / Atom feed
From: Oliver Kiddle <opk@u.genie.co.uk>
To: Zsh workers <zsh-workers@sunsite.dk>
Subject: Re: Moving completion functions
Date: Tue, 20 Mar 2001 21:32:09 +0000	[thread overview]
Message-ID: <3AB7CC59.E566C8A1@u.genie.co.uk> (raw)

Sven wrote:

> Radical idea: let's just wait and do nothing about all this yet.  If

Probably a good plan.

> I don't like _want(|ed)_now, though, because it is too easily confused 
> with _wanted, I think.  And with _wanted we want to add the
> completions *now*, too.

Fair enough. _wanted_yet would possibly address your second point above
but not the first. It would be nice though if we can find some names
which better express the difference between _wanted and _requested. I
can't though and the current names aren't too bad.

> There's now the call to `cvs tag' in it, too.  I think using a tag
> that looks completely different than the version tags is a good idea
> but I otherwise I don't know what to use as a tag.

I agree that it shouldn't look like the version tags. I'd try to use
something which makes it clear that the tag is set before the move -
something like old-comp-dirs or pre-comp-mv. I've never dealt with cvs
tags though so am probably not the best person to answer this.

> Builtins/_popd                  Zsh/Command

_popd could possibly be something like Zsh/Type/_directory_stack as
that is all it completes and it is called by _cd. It might make _cd
more readable and would adapt better to changes in popd's usage.

The script looks fine though I've not looked in as much detail as
before.

Other than the naming of _compalso, _wanted, _requested, _next_label,
_all_labels and the cvs tag are there any other outstanding issues on
this?

Bart wrote:
 
> What exactly would you like fpath to contain by default?  Nothing?

Yes. Unless the parent process exported FPATH to zsh. At the least, we
should change zsh so that if FPATH is set in the environment when it
starts, the completion directories are added to it instead of replacing
it..

> it also sets it to get the stuff from the Functions subdirectory, etc.

I always thought of them as just examples and user contributions as
opposed to being part of zsh's functionality. Before the new
completion, they had to be manually installed and added to $fpath. I've
just noticed though that they are now mentioned in the documentation
which I suppose makes them more official. 

> If we remove the Completion directories from the default fpath, then we
> must also give up --enable-function-subdirs.  Not that we can't use the
> subdirs for installation, but that we must hardwire the installation so
> that compinit can know what to add to fpath.  Even then, compinit needs
> to get the base path (to which to append /Completion/...) from 
> somewhere.

As I said with the original suggestion, there could be a variable set
to point to the base of the installed functions. I don't understand why
compinit would need to know before-hand what directories it should add -
it would just use a bit of globbing modified for $OSTYPE and options
passed to it, I'd be very much against any manufacturing of compinit,
especially while it is installed below /usr/local/share.

> Issues of setting fpath aside, the following patch makes it possible to
> source compinit.  (Not committed yet, pending further discussion.)  One
> thing that bothers me a bit is that the (ARGC=0) test will give the
> wrong result if compinit is sourced from within some other function; as far 
> as
> I can tell, there's no completely reliable way to determine that 
> "source"
> (or ".") is in progress.

The ARGC test thing is clever. Do we need to account for kshautoload
though? How does someone with kshautoload set get the new completion
system to work short of doing unsetopt kshautoload? Having tried a few
ideas, I can't think of any better ways to detect when source is in
progress.

Oliver


             reply	other threads:[~2001-03-20 22:36 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-03-20 21:32 Oliver Kiddle [this message]
2001-03-21  9:58 ` Bart Schaefer
  -- strict thread matches above, loose matches on Subject: below --
2001-03-30 14:00 Sven Wischnowsky
2001-03-30 15:12 ` Bart Schaefer
2001-03-29  9:33 Sven Wischnowsky
2001-03-29 16:49 ` Bart Schaefer
2001-03-28 14:12 Sven Wischnowsky
2001-03-28 16:14 ` Bart Schaefer
2001-03-28 16:20   ` Peter Stephenson
2001-03-26 14:16 Sven Wischnowsky
2001-03-26  8:53 Sven Wischnowsky
2001-03-22 21:46 Oliver Kiddle
2001-03-22 21:50 ` Oliver Kiddle
2001-03-23  0:29 ` Bart Schaefer
2001-03-25 15:26   ` Oliver Kiddle
2001-03-25 20:39     ` Peter Stephenson
2001-03-26  4:33     ` Bart Schaefer
2001-03-22 10:40 Sven Wischnowsky
2001-03-22 11:03 ` Peter Stephenson
2001-03-22 17:04 ` Bart Schaefer
2001-03-21 11:42 Sven Wischnowsky
2001-03-19  9:46 Sven Wischnowsky
2001-03-22  7:21 ` Bart Schaefer
2001-03-18 22:20 Oliver Kiddle
2001-03-19  4:36 ` Bart Schaefer
2001-03-16 17:27 Oliver Kiddle
2001-03-16 10:20 Sven Wischnowsky
2001-03-18  2:39 ` Bart Schaefer
2001-03-15 20:50 Oliver Kiddle
2001-03-16 12:09 ` Peter Stephenson
2001-03-17 23:16 ` Bart Schaefer
2001-03-15 15:46 Oliver Kiddle
2001-03-15 18:14 ` Bart Schaefer
2001-03-15 10:43 Sven Wischnowsky
2001-03-15  9:30 Sven Wischnowsky
2001-03-15 10:33 ` Peter Stephenson
2001-03-15 17:04 ` Bart Schaefer

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=3AB7CC59.E566C8A1@u.genie.co.uk \
    --to=opk@u.genie.co.uk \
    --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).