branch: elpa/bash-completion
commit cad904abfd51ea637cfb28ebe71aeaee12487d4f
Author: Stephane Zermatten <[email protected]>
Commit: Stephane Zermatten <[email protected]>
Redefine quote_readline from setup-bash-common.
quote_readline isn't specific to multi-process situation, so should be
redefined in all cases.
---
bash-completion.el | 14 ++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)
diff --git a/bash-completion.el b/bash-completion.el
index 20a8abc7c0..156e97ebf5 100644
--- a/bash-completion.el
+++ b/bash-completion.el
@@ -425,6 +425,14 @@ returned."
" return $ret; "
"}")
process))
+
+ ;; some bash completion functions use quote_readline
+ ;; to double-quote strings - which compgen understands
+ ;; but only in some environment. disable this dreadful
+ ;; business to get a saner way of handling spaces.
+ ;; Noticed in bash_completion v1.872.
+ (bash-completion-send "function quote_readline { echo \"$1\"; }" process)
+
(bash-completion-send "echo -n ${COMP_WORDBREAKS}" process)
(process-put process 'wordbreaks
(with-current-buffer (bash-completion--get-buffer process)
@@ -1167,12 +1175,6 @@ is set to t."
"export -n MAIL\n"
"export -n MAILPATH\n"
"unset HISTFILE\n"
- ;; some bash completion functions use quote_readline
- ;; to double-quote strings - which compgen understands
- ;; but only in some environment. disable this dreadful
- ;; business to get a saner way of handling spaces.
- ;; Noticed in bash_completion v1.872.
- "function quote_readline { echo \"$1\"; }\n"
;; User's profiles can turn line editing back on,
;; so make sure it's off
"set +o emacs\n"