Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [PATCH] completion for opensolaris IPS package manager



Danek Duvall wrote:
On Sat, Sep 13, 2008 at 05:21:22PM +0200, "xRaich[o]²x" wrote:

I started working on some scripts for opensolaris commands (zpool, zfs, beadm and more are in the works).

Completion functions for zpool and zfs are already in the zsh distribution,
and part of opensolaris (as of build 96), so there's no need to rewrite
those (though perhaps they need enhancement).

#compdef pkg

You keep looking at files under /var/pkg.  These are private interfaces
which could change at any time.  You'd be better off using "pkg list" to
get this information, though you'll probably need to stick the information
in a cache.

Also, "search" doesn't take package names, so it doesn't belong in the same
clause as info and contents.

Thanks!

Danek


I didn't use pkg info because its very slow. i know there is a cache function in zsh completion somewhere but this is actually the first shellscript i ever really wrote ^^.

Thanks for the pointer with zfs und zpool, didn't know that.

Regards,
Björn



Messages sorted by: Reverse Date, Date, Thread, Author