Commit c78f0ca82576d18c624ad282cd3dca575573bc3b

Thomas de Grivel 2015-08-01T01:40:24

Allow ^ in unescaped shell tokens.

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/shell/shell.lisp b/shell/shell.lisp
index 09dd3da..acb85ac 100644
--- a/shell/shell.lisp
+++ b/shell/shell.lisp
@@ -73,7 +73,7 @@ Error: ~S"
 ;;  Shell
 
 (defun sh-quote (string)
-  (if (cl-ppcre:scan "^[-+/=.,:_0-9A-Za-z]*$" string)
+  (if (cl-ppcre:scan "^[-+/=.,:^_0-9A-Za-z]*$" string)
       string
       (str "\"" (cl-ppcre:regex-replace-all "([$`\\\\\"])" string "\\\\\\1") "\"")))