Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Proposed changes to _bsd_pkg -- request for comments
- X-seq: zsh-users 5637
- From: Roman Neuhauser <neuhauser@xxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: Proposed changes to _bsd_pkg -- request for comments
- Date: Fri, 3 Jan 2003 10:14:43 +0100
- In-reply-to: <20030103083927.GB17651@xxxxxxxxxxxxxxxxxxxxxx>
- Mail-followup-to: zsh-users@xxxxxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20030102140412.GG2863@xxxxxxxxxxxxxxxxxxxxxx> <20030103083927.GB17651@xxxxxxxxxxxxxxxxxxxxxx>
# j-devenish@xxxxxxxxxxxxxxxxxxxxx / 2003-01-03 16:39:27 +0800:
> I am looking for some feedback from *BSD users/admins who find
> themselves using zsh's _bsd_pkg completion for pkg_add, pkg_create,
> pkg_delete and pkg_info. I am working with OpenBSD but would really
> appreciate some feedback from someone using _bsd_pkg under FreeBSD.
I don't really use pkg_*, but do use FreeBSD. more below.
> Includes a patch for _bsd_pkg_pkgfiles(), which was matching paths
> against an undefined variable $PKG_PATH. Is this defined under FreeBSD,
> perhaps? I found the completion worked erroneously under OpenBSD.
pkg_add(1):
The value of the PKG_PATH is used if a given package can't be found. The
environment variable should be a series of entries separated by colons.
Each entry consists of a directory name. The current directory may be
indicated implicitly by an empty directory name, or explicitly by a sin
gle period.
I don't use the pkg_* tools, but looks like it should be
${PKG_PATH:-/usr/ports/packages} or something like that.
> My attached version fixes that, and also allows this sort of completion:
> % pkg_add <Tab>
> file1.tgz foo.tgz bar.tgz
> % pkg_add dir1/<Tab>file3.tgz
> % pkg_add databases/<Tab>
> db1.tgz db2.tgz
> % pkg_add foo<Tab>
> pkg_add /usr/ports/packages/blah/All/foo.tgz
> % pkg_add -v foo.tgz
> pkg_add -v /usr/ports/packages/blah/All/foo.tgz
nice!
> I like the "new" behaviour.
so do I. :)
> Basically, the selection list is much more readable and can understand
> packages subdirectories (to help jog one's memory). So far, the latter
> is in a 'case' construct for OpenBSD since I don't know how other BSDs
> lay out their /usr/ports/packages/*.
should be the same.
> Under OpenBSD, the -a option can only be used on its own (no other flags
> or arguments are appropriate). I have implemented this inside a 'case'
> for openbsd*. If the other BSDs are the same, then we can reduce some
> of the 'case' constructs.
A quick test shows that -v, -p, -q, -g further modify the -a output,
others are noop. I haven't found a switch that would make it break
(tried about 1/2 of them)
--
If you cc me or remove the list(s) completely I'll most likely ignore
your message. see http://www.eyrie.org./~eagle/faqs/questions.html
Messages sorted by:
Reverse Date,
Date,
Thread,
Author