diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-17 14:57:17 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-17 14:57:17 +0000 |
commit | 8c80e4dce14eed4e3c06b16fc307c6c7d20b9af8 (patch) | |
tree | 4477eaed15415ddadc3e88205234659628759415 /completions/ssh-add | |
parent | Releasing progress-linux version 1:2.13.0-1~progress7.99u1. (diff) | |
download | bash-completion-8c80e4dce14eed4e3c06b16fc307c6c7d20b9af8.tar.xz bash-completion-8c80e4dce14eed4e3c06b16fc307c6c7d20b9af8.zip |
Merging upstream version 1:2.14.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'completions/ssh-add')
-rw-r--r-- | completions/ssh-add | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/completions/ssh-add b/completions/ssh-add index 23c73e0..0589972 100644 --- a/completions/ssh-add +++ b/completions/ssh-add @@ -10,6 +10,19 @@ _comp_cmd_ssh_add() _comp_compgen -- -W 'md5 sha256' return ;; + -*H) + _comp_compgen_filedir + return + ;; + -*h) + # TODO should we try supporting more types of constraints? + if [[ $cur == *@* ]]; then + _comp_complete_user_at_host "$@" + else + _comp_compgen_known_hosts -- "$cur" + fi + return + ;; -*t) return ;; @@ -17,14 +30,14 @@ _comp_cmd_ssh_add() _comp_compgen_filedir return ;; - -*[se]) + -*S | -*[se]) _comp_compgen_filedir so return ;; esac if [[ $cur == -* ]]; then - _comp_compgen_help -- '-?' + _comp_compgen_usage -- '-?' || _comp_compgen_help -- '-?' return fi |