File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -544,17 +544,17 @@ _comp_xfunc_scp_compgen_local_files()
544544 local files
545545 _comp_expand_glob files ' "$cur"*' || return 0
546546 if [[ $_dirsonly ]]; then
547- _comp_compgen -RU files split -l -- " $(
547+ _comp_compgen -RU files split -l ${1 : +-P " $1 " } -- " $(
548548 command ls -aF1dL " ${files[@]} " 2> /dev/null |
549549 command sed -e " s/$_comp_cmd_scp__path_esc /\\\\ &/g" \
550- -e ' /[^/]$/d' -e " s/^/ ${1-} / "
550+ -e ' /[^/]$/d'
551551 ) "
552552 else
553- _comp_compgen -RU files split -l -- " $(
553+ _comp_compgen -RU files split -l ${1 : +-P " $1 " } -- " $(
554554 command ls -aF1dL " ${files[@]} " 2> /dev/null |
555555 command sed -e ' s/[*@|=]$//g' \
556556 -e " s/$_comp_cmd_scp__path_esc /\\\\ &/g" \
557- -e ' s/[^/]$/& /g' -e " s/^/ ${1-} / "
557+ -e ' s/[^/]$/& /g'
558558 ) "
559559 fi
560560}
You can’t perform that action at this time.
0 commit comments