From: Koichi Murase Date: Tue, 3 Jun 2025 13:08:04 +0000 (+0900) Subject: bash-completion: use "command ls" instead of "\ls" X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=07df800a88635084476c242354736fd4c1f695d6;p=thirdparty%2Futil-linux.git bash-completion: use "command ls" instead of "\ls" The backslash quoting can be used to bypass aliases, but it cannot be used to bypass shell functions for interactive uses defined by the users. We can use "command ls" instead to bypass both aliases and shell functions. --- diff --git a/bash-completion/blkid b/bash-completion/blkid index 175f1746d..a7e4ef5da 100644 --- a/bash-completion/blkid +++ b/bash-completion/blkid @@ -46,7 +46,7 @@ _blkid_module() '-n'|'--match-types') OUTPUT_ALL=" $(command awk '{print $NF}' /proc/filesystems) - $(\ls /lib/modules/$(command uname -r)/kernel/fs) + $(command ls /lib/modules/$(command uname -r)/kernel/fs) " ;; '-h'|'--help'|'-V'|'--version') diff --git a/bash-completion/mount b/bash-completion/mount index 268aa3c79..6175527d8 100644 --- a/bash-completion/mount +++ b/bash-completion/mount @@ -8,7 +8,7 @@ _mount_module() '-t'|'--types') local prefix realcur TYPES TYPES=" - $(\ls /lib/modules/$(command uname -r)/kernel/fs | command awk '{print $1, "no" $1}') + $(command ls /lib/modules/$(command uname -r)/kernel/fs | command awk '{print $1, "no" $1}') $(command awk '{print $NF, "no" $NF}' /proc/filesystems) " realcur="${cur##*,}" diff --git a/bash-completion/umount b/bash-completion/umount index 3b358d0fc..35e86d909 100644 --- a/bash-completion/umount +++ b/bash-completion/umount @@ -42,7 +42,7 @@ _umount_module() '-t'|'--types') local TYPES TYPES=" - $(\ls /lib/modules/$(command uname -r)/kernel/fs | command awk '{print $1, "no" $1}') + $(command ls /lib/modules/$(command uname -r)/kernel/fs | command awk '{print $1, "no" $1}') $(command awk '{print $NF, "no" $NF}' /proc/filesystems) " COMPREPLY=( $(compgen -W "$TYPES" -- $cur) )