[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master b4492a3 002/399: counsel.el (counsel-git-checkout-action):
From: |
Oleh Krehel |
Subject: |
[elpa] master b4492a3 002/399: counsel.el (counsel-git-checkout-action): Quote branch names |
Date: |
Sat, 20 Jul 2019 14:56:36 -0400 (EDT) |
branch: master
commit b4492a301ac00b5aefbcdf89ae36924055e4256d
Author: Hans Jerry Illikainen <address@hidden>
Commit: Hans Jerry Illikainen <address@hidden>
counsel.el (counsel-git-checkout-action): Quote branch names
Quoting branch names is necessary to avoid executing shell
substitutions.
Fixes #1905.
---
counsel.el | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/counsel.el b/counsel.el
index ee78d9f..af83039 100644
--- a/counsel.el
+++ b/counsel.el
@@ -1694,7 +1694,9 @@ The command is passed a single argument comprising all
characters
in BRANCH up to, but not including, the first space
character (#x20), or the string's end if it lacks a space."
(shell-command
- (format "git checkout %s" (substring branch 0 (string-match-p " "
branch)))))
+ (format "git checkout %s"
+ (shell-quote-argument
+ (substring branch 0 (string-match-p " " branch))))))
(defun counsel-git-branch-list ()
"Return list of branches in the current git repository.
- [elpa] master updated (64d03d9 -> 33689c1), Oleh Krehel, 2019/07/20
- [elpa] master b4492a3 002/399: counsel.el (counsel-git-checkout-action): Quote branch names,
Oleh Krehel <=
- [elpa] master 100bd21 001/399: counsel.el (counsel-M-x): Optionally expand aliases, Oleh Krehel, 2019/07/20
- [elpa] master 08dd58b 003/399: ivy.el (ivy--regex-fuzzy): Don't allow newlines in wildcards, Oleh Krehel, 2019/07/20
- [elpa] master 70ad031 004/399: doc/Changelog.org: Update path to CSS, Oleh Krehel, 2019/07/20
- [elpa] master 596461e 005/399: counsel.el (counsel-grep-use-swiper-p): New defcustom, Oleh Krehel, 2019/07/20
- [elpa] master 6017cc8 006/399: ivy.el (ivy-read): Keep only one action for one key, Oleh Krehel, 2019/07/20
- [elpa] master dc250bd 008/399: counsel.el (counsel-unicode-char): Don't sort every time, Oleh Krehel, 2019/07/20
- [elpa] master b000b0a 007/399: ivy.el (ivy--recompute-index): Speed up, Oleh Krehel, 2019/07/20
- [elpa] master c2eb4b5 009/399: ivy.el (ivy--kill-buffer-action): Integrate with ivy-switch-buffer-kill, Oleh Krehel, 2019/07/20
- [elpa] master f631d75 013/399: swiper.el (swiper-font-lock-exclude): Add xref--xref-buffer-mode, Oleh Krehel, 2019/07/20
- [elpa] master 3773c26 015/399: swiper.el (swiper--current-window-start): Add docstring, Oleh Krehel, 2019/07/20