[Bash-completion-commits] ./current r1203: Allow configfile to contain spaces
David Paleino
d.paleino at gmail.com
Sat Nov 8 08:45:31 UTC 2008
------------------------------------------------------------
revno: 1203
committer: David Paleino <d.paleino at gmail.com>
branch nick: current
timestamp: Sat 2008-11-08 09:45:31 +0100
message:
Allow configfile to contain spaces
modified:
contrib/ssh
debian/changelog
-------------- next part --------------
=== modified file 'contrib/ssh'
--- a/contrib/ssh 2008-11-01 11:25:38 +0000
+++ b/contrib/ssh 2008-11-08 08:45:31 +0000
@@ -31,17 +31,17 @@
while [ $# -gt 0 ]; do
if [ "${1:0:2}" = -F ]; then
if [ ${#1} -gt 2 ]; then
- optconfigfile="$1"
+ optconfigfile="$(dequote "$1")"
else
shift
- optconfigfile="-F$1"
+ [ "$1" ] && optconfigfile="$(dequote "-F$1")"
fi
break
fi
shift
done
- _known_hosts -a $optconfigfile
+ _known_hosts -a "$optconfigfile"
[ $COMP_CWORD -eq 1 -o -n "$optconfigfile" ] || \
COMPREPLY=( "${COMPREPLY[@]}" $( compgen -c -- $cur ) )
@@ -89,17 +89,17 @@
while [ $# -gt 0 ]; do
if [ "${1:0:2}" = -F ]; then
if [ ${#1} -gt 2 ]; then
- optconfigfile="$1"
+ optconfigfile="$(dequote "$1")"
else
shift
- optconfigfile="-F$1"
+ [ "$1" ] && optconfigfile="$(dequote "-F$1")"
fi
break
fi
shift
done
- [[ "$cur" == */* ]] || _known_hosts -c -a $optconfigfile
+ [[ "$cur" == */* ]] || _known_hosts -c -a "$optconfigfile"
local IFS=$'\t\n'
COMPREPLY=( "${COMPREPLY[@]}" $( command ls -aF1d $cur* \
2>/dev/null | sed \
=== modified file 'debian/changelog'
--- a/debian/changelog 2008-11-08 08:40:53 +0000
+++ b/debian/changelog 2008-11-08 08:45:31 +0000
@@ -40,7 +40,7 @@
(Closes: #504547)
* debian/links fixed (Closes: #494292)
- -- David Paleino <d.paleino at gmail.com> Sat, 08 Nov 2008 09:39:48 +0100
+ -- David Paleino <d.paleino at gmail.com> Sat, 08 Nov 2008 09:43:59 +0100
bash-completion (20080705) unstable; urgency=low
More information about the Bash-completion-commits
mailing list