TAB autocomplete does not work correctly for "chown user:group"
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
bash-completion |
Unknown
|
Unknown
|
|||
bash-completion (Debian) |
Fix Released
|
Unknown
|
|||
bash-completion (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: bash-completion
bash-completion does not work correctly for chown.
try the following:
go into a dir as root, and type:
mkdir test
$ ls -l
insgesamt 4
drwxr-xr-x 2 root root 4096 2008-08-05 19:10 test
now type
$ chown ma[TAB]
it tries autocompletes and suggests:
mail: man:
There are the colons, auto-completion does not delete them. Therefore, if you press another 'i' ->for 'mail' or just type
$ chown mai[TAB]
it auto-completes to
$ chown mail\:
with a trailing space - this is useless.
if you type
$ chown mail:[TAB]
it shows the correct groups.
I think the autocomplete feature forgets to delete the trailing colon and interprets it as part of the user to search for.
Changed in bash-completion (Debian): | |
status: | Unknown → Confirmed |
Changed in bash-completion (Debian): | |
status: | Confirmed → Fix Released |
Changed in bash-completion (Ubuntu): | |
status: | Confirmed → Fix Released |
I think problem is the file /etc/bash_ completion.
at line 3236 it says:
# remove any \: generated by a command that doesn't
# default to filenames or dirnames (e.g. sudo chown)
# FIXME: I'm pretty sure this does not work!
But it doesn't matter whether you say
chown or 'sudo chown' or 'sudo -s' and then chown.
Despite the FIXME I didn't find a bug report...