util-linux/backport-su-bash-completion-offer-usernames-rather-than-files.patch

28 lines
739 B
Diff
Raw Normal View History

2022-06-20 17:29:05 +08:00
From 49609c78e9441dab686da4eda38df1dcca3cacc9 Mon Sep 17 00:00:00 2001
From: Karel Zak <kzak@redhat.com>
Date: Tue, 31 Aug 2021 12:51:40 +0200
Subject: [PATCH] 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>
---
bash-completion/su | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bash-completion/su b/bash-completion/su
index 3095050..913e445 100644
--- a/bash-completion/su
+++ b/bash-completion/su
@@ -41,7 +41,7 @@ _su_module()
esac
local IFS=$'\n'
compopt -o filenames
- COMPREPLY=( $(compgen -f -- $cur) )
+ COMPREPLY=( $(compgen -u -- $cur) )
return 0
}
complete -F _su_module su
--
1.8.3.1