[Bash-completion-devel] I filed some bugs in the tracker with patches

Peter Cordes peter at cordes.ca
Tue Dec 2 16:11:14 UTC 2014


 Should I send mail here to get someone's attention?  Or is filing
bugs with [patch] in the name a good way to go?

 I rebased all my recent patches against the current git head, and
attached them, in case anyone else thinks they're interesting.

 I've been going through Ubuntu's
https://bugs.launchpad.net/ubuntu/+source/bash-completion
and closed about 25 bugs that didn't exist anymore, but hadn't been
marked Fix Released.  Or that were invalid.  I fixed some others, or
at least submitted them upstream to Alioth.

 I also wrote patches for apport and dput completions, and reassigned
those bugs to the right packages.  (people don't check if a package
supplies its own completions before filing a bug with bash-completion.)

 I also had some thoughts on how Ubuntu enables completion out of the
box for login shells but not non-login shells.  (tl;dr: that's silly.)
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1173728
If Debian is the same way, then my suggestion to use /etc/skel/.bashrc
applies there, too.


 Anyway, here are my patches.  It'd be cool if the useful ones got
applied.  And if someone could explain why the non-useful ones aren't.
:P

 There are still some problems that I haven't really looked into
trying to fix, like:
No completion of filenames inside ` or $() command substitution
https://alioth.debian.org/tracker/index.php?func=detail&aid=314895&group_id=100114&atid=413095


BTS links for my patches:

bugfix for unquoted use of a variable that could contain * and cause
problems.  (on Ubuntu 14.04's version of bash_completion, this fixed
ls /s*[TAB] -> /sbin, even when there were multiple possible results.
git head doesn't have this problem, even with the unquoted use, but
IDK why.)
https://alioth.debian.org/tracker/index.php?func=detail&aid=314891&group_id=100114&atid=413095

Some code cleanup, quoting more stuff that was used unquoted.
Probably just cosmetic.  (patches 2 and 3)
https://alioth.debian.org/tracker/index.php?func=detail&aid=314892&group_id=100114&atid=413095

More restrictive test before an eval, prevented an error in Ubuntu
14.04's bash_completion, but no effect on git head behaviour.
I don't understand this code well enough to be sure this is a good
change. >.<
https://alioth.debian.org/tracker/?func=detail&aid=314667&group_id=100114&atid=413095

_longopt: correctly handle things like grep's --help output line:
  -r, --recursive           like --directories=recurse
 And try to complete on options if the word begins with -, regardless
of what our heuristics say this word should be.  Don't get in the way
of the user.
https://alioth.debian.org/tracker/?func=detail&group_id=100114&aid=314896&atid=413095

upstart support for listing services
https://alioth.debian.org/tracker/?func=detail&group_id=100114&aid=314897&atid=413095


prefetch /etc/bash_completion.d/* into disk cache in the background
https://alioth.debian.org/tracker/index.php?func=detail&aid=314901&group_id=100114&atid=413095


-- 
#define X(x,y) x##y
Peter Cordes ;  e-mail: X(peter at cor , des.ca)

"The gods confound the man who first found out how to distinguish the hours!
 Confound him, too, who in this place set up a sundial, to cut and hack
 my day so wretchedly into small pieces!" -- Plautus, 200 BC
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-fix-_filedir-unquoted-use-of-user-input.patch
Type: text/x-diff
Size: 1374 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Quote-some-unquoted-uses-variables.patch
Type: text/x-diff
Size: 2648 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0003-More-tidier-quoting-on-evals.patch
Type: text/x-diff
Size: 2227 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0002.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0004-_quote_readline_by_ref-only-eval-if-the-string-start.patch
Type: text/x-diff
Size: 1335 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0003.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0005-_longopt-fix-parsing-help-output-that-has-in-the-des.patch
Type: text/x-diff
Size: 3559 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0004.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0006-upstart-support-for-service-completion.patch
Type: text/x-diff
Size: 1482 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0005.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0007-speed-up-loading-the-compat-dir-with-disk-prefetch.patch
Type: text/x-diff
Size: 3993 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment-0006.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 359 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/bash-completion-devel/attachments/20141202/bdcf6ae2/attachment.sig>


More information about the Bash-completion-devel mailing list