Skip to content

Commit c6decb1

Browse files
committed
Avoid escaping all non-ASCII characters.
This change updates the set of special chars to not include non-ASCII chars. The previous set of special chars to escape was previously defined by a list of characters *not* to escape, which included only ASCII characters. This meant that anything non-ascii would be escaped, and unnecessarily so since these characters are not special for bash.
1 parent 51c7770 commit c6decb1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bash-completion.el

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ explanation.")
253253
Mapping between remote paths as returned by `file-remote-p' and
254254
Bash processes.")
255255

256-
(defconst bash-completion-special-chars "[^-0-9a-zA-Z_./\n=]"
256+
(defconst bash-completion-special-chars "[ -$&-*,:-<>?[-^`{-}]"
257257
"Regexp of characters that must be escaped or quoted.")
258258

259259
(defconst bash-completion--ps1 "'\t$?\v'"

0 commit comments

Comments
 (0)