[Bash-completion-devel] some patches from a git repo
gibboris at gmail.com
Tue May 3 18:42:29 UTC 2011
On Tue, May 03, 2011 at 09:22:00PM +0300, Ville Skyttä wrote:
> On 04/06/2011 04:29 PM, Raph wrote:
> > Hi,
> > here I put some bash-completion stuff there:
> > https://gitorious.org/drzraf/bash-completion
> Sorry for taking so long, here are some comments and excuses ;)
> > You'll find:
> > - the patch for #311708
> I'm not convinced we will need something like this. There's already
> ~/.bash_completion in which users can do whatever they like, ditto
> /etc/profile.d/bash_completion.sh. We've just removed all these dir
> variables except the compat dir one, and things will probably continue
> to change once we get to taking full advantage of bash 4.1+'s features
> (dynamic loading etc).
> > - a slightly modified ifscheme completion (which was lost in translation)
> I don't know that command (seems Debian specific?), but eyeballing the
> completion, at least it should make $schemes local.
ifscheme is Debian specific but its completion used to be released
within older bash-completion releases.
> > - a (still buggy) burn-cd completion
> This is another command I don't know or seem to have available, and I
> don't feel comfortable with applying something that's known to be buggy
I understand, I still need to think which features can be implemented
(especially the gauge)
> > - a mysql client completion based on the mysqladmin script
> This I intend to look closer into sometime. But here are the first few
> -D|--database: What's the -E argument to sed?
Extended regexp (to avoid too much backslashes) but I not sure whether or not
> -D|--database: mysqlshow may exit with an error (permission denied etc),
> I suppose it needs a 2>/dev/null.
> --default-character-set: the -I argument to ls is not portable, and I
> suppose this could be done fairly easily without ls and sed
At the time I wrote it I didn't find alternative as the mysql doc stated
that the mysql client look into this directory to find encodings.
> (long list of hardcoded options): Could most likely use _parse_help for
> this now.
> > - a fix for the sitecopy completion
> > - the (... omg ...) tc(1) completion (may be useful for the ip(1) comp)
> I have no clue about these commands, someone more familiar with them
> should look into them.
tc is "traffic control" part of the iproute (2) package.
Most of its syntax applies to /bin/ip for which I recently saw a thread.
Two years ago I created the functions needed to parse the whole command line
and analyze the arguments.
Part of this is now implemented in _*, I should use it.
> > - 2 versions of the wget completion
> Why 2 versions? What are the differences, and which one do you
> recommend? I don't think we want more than one completion per
bash 4 and bash 3 compatible versions (-o filenames, ...)
> All completions could be updated/"modernized" to take advantage of some
> recently added goodies available in git, but those can be done after
> merging. Test cases for the new commands and the fixed bugs would be nice.
I will follow your advices and modernize according to your remarks, as
soon as I have the time needed.
Thank you for your review !
More information about the Bash-completion-devel