[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/bash-completion 38c82e5d59 252/313: Conserve quotes even w
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/bash-completion 38c82e5d59 252/313: Conserve quotes even when expanding case-insensitively. |
Date: |
Sat, 3 Dec 2022 10:59:35 -0500 (EST) |
branch: elpa/bash-completion
commit 38c82e5d5943f409f55d3f1b7a7f55d3fa2e6aae
Author: Stephane Zermatten <szermatt@gmx.net>
Commit: Stephane Zermatten <szermatt@gmx.net>
Conserve quotes even when expanding case-insensitively.
---
bash-completion.el | 9 +++++----
test/bash-completion-integration-test.el | 7 +++++++
2 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/bash-completion.el b/bash-completion.el
index 4c2f59b7e4..9836051d3f 100644
--- a/bash-completion.el
+++ b/bash-completion.el
@@ -1005,10 +1005,11 @@ for directory name detection to work."
;; Bypass the whole prefix/suffix logic and replace the string
;; being completed with the string provided by the completion
;; logic.
- (t (setq unparsed-prefix ""
- parsed-prefix ""
- rest str)))
-
+ (t
+ (setq parsed-prefix ""
+ unparsed-prefix (if open-quote (char-to-string open-quote) "")
+ rest str)))
+
;; build suffix
(let ((last-char (bash-completion-last-char rest))
(close-quote-str (if open-quote (char-to-string open-quote) ""))
diff --git a/test/bash-completion-integration-test.el
b/test/bash-completion-integration-test.el
index 09b190b166..53435cc268 100644
--- a/test/bash-completion-integration-test.el
+++ b/test/bash-completion-integration-test.el
@@ -395,6 +395,7 @@ for testing completion."
(with-temp-file "test-inputrc"
(insert "set completion-ignore-case on\n"))
(make-directory "Uppercase")
+ (make-directory "Another Uppercase")
(bash-completion_test-with-shell
(when (>= (bash-completion_test-bash-major-version) 4)
;; Case insensitive completion is done by compgen which, under
@@ -404,6 +405,12 @@ for testing completion."
(should (equal "ls some/" (bash-completion_test-complete "ls So")))
(should (equal "ls Uppercase/" (bash-completion_test-complete "ls Up")))
(should (equal "ls Uppercase/" (bash-completion_test-complete "ls up")))
+ (should (equal "ls Another\\ Uppercase/" (bash-completion_test-complete
"ls Ano")))
+ (should (equal "ls Another\\ Uppercase/" (bash-completion_test-complete
"ls ano")))
+ (should (equal "ls \"Another Uppercase/" (bash-completion_test-complete
"ls \"Ano")))
+ (should (equal "ls \"Another Uppercase/" (bash-completion_test-complete
"ls \"ano")))
+ (should (equal "ls 'Another Uppercase/" (bash-completion_test-complete
"ls 'Ano")))
+ (should (equal "ls 'Another Uppercase/" (bash-completion_test-complete
"ls 'ano")))
(should completion-ignore-case)))))
(ert-deftest bash-completion-integration-case-sensitive-test ()
- [nongnu] elpa/bash-completion ac3bd404e8 220/313: Fix typos (#40), (continued)
- [nongnu] elpa/bash-completion ac3bd404e8 220/313: Fix typos (#40), ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion f31bb46ff4 222/313: Making sure that line editing is turned off (#42), ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 3210a44081 224/313: Makefile allows specifying the path to bash., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 2178030cdf 225/313: Allow running unit and integration tests separately., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion c564aff656 229/313: Add workflow for testing on MacOS with BASH 3., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion ba8be293a4 226/313: Added test workflow to run tests on multiple versions of Emacs., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 0a757bd5f4 238/313: Test calling completion from non-comint and non-bash shell buffers., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion c99083233f 241/313: Fix shell-type detection logic for remote processes., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 4a1d89f01e 246/313: Support -o vi and emacs even in single-process mode., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion aec357fbf1 249/313: Test default completion with both value of use-separate-process., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 38c82e5d59 252/313: Conserve quotes even when expanding case-insensitively.,
ELPA Syncer <=
- [nongnu] elpa/bash-completion 6a66eeda45 253/313: Add test-case to cover tilde and tilde expansion., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion b9e519e2ad 263/313: Fix typo, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 2684ea9e46 264/313: Fix issue with case-insensitive completion., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 6d74dd30ba 266/313: Avoid interference from PROMPT_COMMAND in single process mode., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 23a3402844 270/313: Trying to disable the warning on MacOS that breaks the tests., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 1598101f06 271/313: Remove the fallback to a separate process., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 18ed1504ce 274/313: Add test cases for TRAMP shell., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 23dbe5b537 276/313: Change minimum supported Emacs version from 24.1 to 24.3., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion c3797e0d09 277/313: Avoid running the same completion multiple times., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 0210d346f1 279/313: Make bash-completion-use-separate-processes default to nil., ELPA Syncer, 2022/12/03