This patch brings support for automatic dangerous shell characters
escape in umount autocompletion. Due to the very peculiar way for
bash to handle autocompletion routines, proper escaping of the shell
sequences only worked properly inside a function: _umount_point_list,
which will add to the user's namespace at the next umount attempt of
autocompleting mount point.
It also translates calls of gensub to the portable alternatives sub
and gsub, in order to allow the use of various awk implementations
(mawk, Gnu, Busybox, etc), and as such kind of undoes a recent change
to enforce the use of Gnu awk. The whole story landed into the Debian
BTS initially:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=933934
PS: It's been a few months since the patch is available, sorry for the
delay; I only got myself a Github account quite recently...
Signed-off-by: Étienne Mollier <etienne.mollier@mailoo.org>
gensub() is a gawk extension, so use it explicitly. Otherwise users will
get an error if their 'awk' defaults to something else.
Fixes: 3ebfc8d37 ("bash-completion: umount support relative path and ~ as home shorthands")
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Check what has changed in usage functions in between v2.32..a77bd80d5 and
update bash-completion files accordingly.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
# mount /dev/sdc1 /mnt/test/foo\ bar
# umount <tab>
has to return "/mnt/test/foo\ bar".
Changes:
* don't use mount | awk output, we have findmnt
* force compgen use \n as entries separator
Addresses: https://github.com/karelzak/util-linux/issues/539
Signed-off-by: Karel Zak <kzak@redhat.com>
The xiafs filesystem was removed from the kernel fifteen years ago,
and any kernel that contained it reached end of life ten years ago.
It's time to stop mentioning it in the mount man page and elsewhere.
Signed-off-by: Benno Schulenberg <bensberg@justemail.net>