su: (bash-completion) offer usernames rather than files

Fixes: https://github.com/karelzak/util-linux/issues/1424
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2021-08-31 12:51:40 +02:00
parent 9714331843
commit 059811d096
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ _su_module()
esac esac
local IFS=$'\n' local IFS=$'\n'
compopt -o filenames compopt -o filenames
COMPREPLY=( $(compgen -f -- $cur) ) COMPREPLY=( $(compgen -u -- $cur) )
return 0 return 0
} }
complete -F _su_module su complete -F _su_module su