Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 171381 - zsh-completion for eselect
Summary: zsh-completion for eselect
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: eselect (show other bugs)
Hardware: All All
: High enhancement (vote)
Assignee: Gentoo eselect Team
Depends on:
Reported: 2007-03-18 20:31 UTC by David Durrleman
Modified: 2008-01-11 05:52 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---

a zsh completion function for eselect (_eselect,1.35 KB, text/plain)
2007-03-18 20:32 UTC, David Durrleman
a better zsh completion function for eselect (_eselect,1.13 KB, text/plain)
2007-03-19 02:20 UTC, David Durrleman
Version without sed (_eselect,1.20 KB, text/plain)
2007-10-29 16:17 UTC, Bapt

Note You need to log in before you can comment on or make changes to this bug.
Description David Durrleman 2007-03-18 20:31:55 UTC
zsh-completion currently doesn't support eselect.

I have written an _eselect function that does the work. I will attach it to this bug.

It doesn't support every options of eselect (e.g the "--global" in "eselect bashcomp list --global"), but it supports as much as the bash-completion equivalent does.

Please comment, and if you find it acceptable, include it in the zsh-completion package.

Reproducible: Always

Steps to Reproduce:
1. run zsh
2. type eselect <tab>
Actual Results:  
file completion occurs

Expected Results:  
eselect modules completion should have occurred
Comment 1 David Durrleman 2007-03-18 20:32:53 UTC
Created attachment 113708 [details]
a zsh completion function for eselect
Comment 2 David Durrleman 2007-03-19 02:20:44 UTC
Created attachment 113749 [details]
a better zsh completion function for eselect

I rewrote it because it was badly written. Here it is.
Comment 3 Mike Kelly (RETIRED) gentoo-dev 2007-03-29 08:45:39 UTC
Mamoru, how does this script look to you? Would you want to include it in the main zsh-completion package? Or would you rather we package it with eselect?
Comment 4 Doug Goldstein gentoo-dev 2007-08-24 16:38:30 UTC
Comment 5 Bapt 2007-10-29 15:30:26 UTC
The code is not good because, it doesn't work at least on gentoo/freebsd because of the sed command,

I'll try to remove sed and use a pure zsh way to do the job.

Anyway, I think this should be incorporated in zsh-completion, because zsh-completion already provides the completion for most of the gentoo tools.
Comment 6 Bapt 2007-10-29 16:17:55 UTC
Created attachment 134650 [details]
Version without sed

Here is a new version based on David's one which avoid the use of sed.

Also remove the french header :).

please test it (I can only test on gentoo/freebsd)

In zsh completion function, it is better to use built-in function each time it is possible (sed for example is not always portable)
Comment 7 Saleem Abdulrasool (RETIRED) gentoo-dev 2008-01-11 05:52:11 UTC
Added with 20080110