summaryrefslogtreecommitdiffstats
path: root/completions/ssh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-17 14:57:17 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-17 14:57:17 +0000
commit8c80e4dce14eed4e3c06b16fc307c6c7d20b9af8 (patch)
tree4477eaed15415ddadc3e88205234659628759415 /completions/ssh
parentReleasing progress-linux version 1:2.13.0-1~progress7.99u1. (diff)
downloadbash-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')
-rw-r--r--completions/ssh8
1 files changed, 4 insertions, 4 deletions
diff --git a/completions/ssh b/completions/ssh
index 386fd25..561dd07 100644
--- a/completions/ssh
+++ b/completions/ssh
@@ -404,7 +404,7 @@ _comp_cmd_sftp()
# Prefer `ssh` from same dir for resolving options, etc
local pathcmd
- pathcmd=$(type -P "$1") && local PATH=${pathcmd%/*}:$PATH
+ pathcmd=$(type -P -- "$1") && local PATH=${pathcmd%/*}:$PATH
_comp_xfunc_ssh_compgen_suboption_check && return
@@ -469,7 +469,7 @@ _comp_cmd_scp__path_esc='[][(){}<>"'"'"',:;^&!$=?`\\|[:space:]]'
_comp_xfunc_scp_compgen_remote_files()
{
# remove backslash escape from the first colon
- cur=${cur/\\:/:}
+ local cur=${cur/\\:/:}
local _userhost=${cur%%?(\\):*}
local _path=${cur#*:}
@@ -499,7 +499,7 @@ _comp_xfunc_scp_compgen_remote_files()
command sed -e 's/'"$_comp_cmd_scp__path_esc"'/\\\\\\&/g' -e 's/[*@|=]$//g' \
-e 's/[^\/]$/& /g')
fi
- _comp_compgen_split -l -- "$_files"
+ _comp_compgen -R split -l -- "$_files"
}
# @deprecated 2.12 use `_comp_compgen -ax ssh remote_files` instead
@@ -556,7 +556,7 @@ _comp_cmd_scp()
# Prefer `ssh` from same dir for resolving options, remote files, etc
local pathcmd
- pathcmd=$(type -P "$1") && local PATH=${pathcmd%/*}:$PATH
+ pathcmd=$(type -P -- "$1") && local PATH=${pathcmd%/*}:$PATH
_comp_xfunc_ssh_compgen_suboption_check && {
((${#COMPREPLY[@]})) && COMPREPLY=("${COMPREPLY[@]/%/ }")