Skip to content

Commit

Permalink
_included_ssh_config_files: store found included files in an array
Browse files Browse the repository at this point in the history
Seemingly this was the intent all along.
  • Loading branch information
scop committed Apr 23, 2019
1 parent bae4a3d commit 6d01267
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bash_completion
Original file line number Diff line number Diff line change
Expand Up @@ -1455,7 +1455,7 @@ _included_ssh_config_files()
echo "bash_completion: $FUNCNAME: missing mandatory argument CONFIG" >&2
local configfile i f
configfile=$1
local included=$(command sed -ne 's/^[[:blank:]]*[Ii][Nn][Cc][Ll][Uu][Dd][Ee][[:blank:]]\{1,\}\([^#%]*\)\(#.*\)\{0,1\}$/\1/p' "${configfile}")
local included=( $(command sed -ne 's/^[[:blank:]]*[Ii][Nn][Cc][Ll][Uu][Dd][Ee][[:blank:]]\{1,\}\([^#%]*\)\(#.*\)\{0,1\}$/\1/p' "${configfile}") )
for i in ${included[@]}; do
# Check the origin of $configfile to complete relative included paths on included
# files according to ssh_config(5):
Expand Down

0 comments on commit 6d01267

Please sign in to comment.