[Bash-completion-commits] [SCM] bash-completion branch, master, updated. 5a29589fcadeac3ae9f1f5f2f8600468d3f90d39
Guillaume Rousse
guillomovitch at zarb.org
Sat Apr 3 19:42:19 UTC 2010
The following commit has been merged in the master branch:
commit 5a29589fcadeac3ae9f1f5f2f8600468d3f90d39
Author: Guillaume Rousse <guillomovitch at zarb.org>
Date: Sat Apr 3 21:42:13 2010 +0200
fix _filedir completion for path with non-ascii chars, by evaluating the result of _quote_readline_by_ref
diff --git a/bash_completion b/bash_completion
index 024b4e0..8626fd2 100644
--- a/bash_completion
+++ b/bash_completion
@@ -590,7 +590,10 @@ _filedir()
#
if [[ "$1" != -d ]]; then
xspec=${1:+"!*.$1"}
- if [[ ${cur:0:1} == "'" && ${BASH_VERSINFO[0]} -ge 4 ]]; then
+ # in some situation, _quote_readline_by_ref actually overquote,
+ # hence the need to eval the result
+ if [[ ${cur:0:1} == "'" && ${BASH_VERSINFO[0]} -ge 4 ]] || \
+ [[ ${quoted:0:1} == '$' ]]; then
toks=( ${toks[@]-} $(
eval compgen -f -X \"\$xspec\" -- $quoted
) )
--
bash-completion
More information about the Bash-completion-commits
mailing list