[Bash-completion-devel] xsltproc completion

Ville Skyttä ville.skytta at iki.fi
Tue May 26 18:49:39 UTC 2009


On Monday 25 May 2009, Raph wrote:
> Hello,
> a quick attempt to make the
> completion of xsltproc.
> See attachement.
[...]
>      --encoding)
>          COMPREPLY=( $(compgen -W "$(localedef --list-archive)" -- "$cur" ))

On a very brief look [0], this doesn't seem right to me.  localedef --list-
archive returns quite a bit of other things than character encodings at least 
on my Fedora 10 box:

$ localedef --list-archive | head -n 10
aa_DJ
aa_DJ.iso88591
aa_DJ.utf8
aa_ER
aa_ER.utf8
aa_ER.utf8 at saaho
aa_ER at saaho
aa_ET
aa_ET.utf8
af_ZA

...and localedef seems to be something entirely different on Solaris.  locale 
-a would seem more portable (if it is the right tool for this job in the first 
place; perhaps iconv -l would be better).

[0] IMHO contributions that are more than a few lines of trivial patches are 
less likely to fall through the cracks if they're submitted in the alioth 
tracker rather than posted here...



More information about the Bash-completion-devel mailing list