[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/bash-completion 9583153e0b 068/313: Fixed issue with wordb
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/bash-completion 9583153e0b 068/313: Fixed issue with wordbreak character being the first character |
Date: |
Sat, 3 Dec 2022 10:59:17 -0500 (EST) |
branch: elpa/bash-completion
commit 9583153e0ba99a5158c79a8f14fd7ff62006afa8
Author: Stephane Zermatten <szermatt@gmx.net>
Commit: Stephane Zermatten <szermatt@gmx.net>
Fixed issue with wordbreak character being the first character
---
bash-completion.el | 4 ++--
bash-completion_test.el | 2 ++
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/bash-completion.el b/bash-completion.el
index ef8d80c201..5dccc8cb5b 100644
--- a/bash-completion.el
+++ b/bash-completion.el
@@ -190,7 +190,7 @@ This function is not meant to be called outside of
(bash-completion-send (concat
(bash-completion-cd-command-prefix)
"compgen -o default -- "
- after-wordbreak))
+ (bash-completion-quote after-wordbreak)))
(comint-dynamic-simple-complete
after-wordbreak
(bash-completion-extract-candidates after-wordbreak)))))
@@ -664,7 +664,7 @@ Wordbreaks characters are defined in
'bash-completion-wordbreak'.
Return a CONS containing (before . after)."
(catch 'bash-completion-return
(let ((end (- (length str) 1)))
- (while (> end 0)
+ (while (>= end 0)
(when (memq (aref str end) bash-completion-wordbreaks)
(throw 'bash-completion-return (cons (substring str 0 (1+ end))
(substring str (1+ end)))))
(setq end (1- end))))
diff --git a/bash-completion_test.el b/bash-completion_test.el
index 2d10eb5645..24637c07f6 100644
--- a/bash-completion_test.el
+++ b/bash-completion_test.el
@@ -424,10 +424,12 @@ garbage
(bash-completion-last-wordbreak-split "a:b:c:d:e")
(bash-completion-last-wordbreak-split "hello=world")
(bash-completion-last-wordbreak-split "hello>world")
+ (bash-completion-last-wordbreak-split ">world")
(bash-completion-last-wordbreak-split "hello"))
'(("a:b:c:d:" . "e")
("hello=" . "world")
("hello>" . "world")
+ (">" . "world")
("" . "hello")))
- [nongnu] elpa/bash-completion c28492a749 036/313: wordbreak before and after, (continued)
- [nongnu] elpa/bash-completion c28492a749 036/313: wordbreak before and after, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 8b02aafc67 046/313: separators, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 2390d5cdf3 061/313: more commends and documentation; still need a commentary section, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion c0f7c20a6b 094/313: added license and missing test dependency, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion a2d322fb79 054/313: Added customization group, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 983f5c28e9 106/313: Merge pull request #2 from frankpzh/patch-1, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 9f02a62609 049/313: re-enabled parse-line cursor at the beginning/in the middle tests, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 3ec615a4ef 077/313: added id, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion f1d8d73b42 072/313: changed comment, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 2d6ad3980a 062/313: fixes for emacs 22, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 9583153e0b 068/313: Fixed issue with wordbreak character being the first character,
ELPA Syncer <=
- [nongnu] elpa/bash-completion 7dec35f302 087/313: Set MAIL to the empty string in case shopt -u mailwarn is not, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 8a246f40da 088/313: bash-completion-generate-line: add missing compgen option to, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 6fb6bf5588 081/313: Mention ghardy bash version, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 33ed66e567 099/313: bash-completion-nospace option, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion cf42ed1057 101/313: add compatibility information for emacs 24.1.1 with OSX 10.7 / 10.8, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion f9903d4bd4 079/313: ran checkdoc again, re-ran integration tests, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion bab4cf6e8d 109/313: Merge remote-tracking branch 'origin/master' into complete_D, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion dce43a54c5 119/313: Update comment in bash-completion-test, ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 5209200f3b 120/313: Using cl-letf instead of flet., ELPA Syncer, 2022/12/03
- [nongnu] elpa/bash-completion 9588a9c0dd 125/313: Updated README, ELPA Syncer, 2022/12/03