[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/multishell ee12b22 08/23: Unravel conditional tangle (a
From: |
Stefan Monnier |
Subject: |
[elpa] externals/multishell ee12b22 08/23: Unravel conditional tangle (and use bound-and-true-p) |
Date: |
Sun, 29 Nov 2020 23:19:37 -0500 (EST) |
branch: externals/multishell
commit ee12b22501f2ce5c1a742fe43dee5e221de0a018
Author: Ken Manheimer <ken.manheimer@gmail.com>
Commit: Ken Manheimer <ken.manheimer@gmail.com>
Unravel conditional tangle (and use bound-and-true-p)
Also include some code formatting refinements.
From gnu people's fixes.
---
multishell.el | 23 ++++++++++-------------
1 file changed, 10 insertions(+), 13 deletions(-)
diff --git a/multishell.el b/multishell.el
index 88f8789..fb1dd39 100644
--- a/multishell.el
+++ b/multishell.el
@@ -203,28 +203,25 @@ If optional UNBIND is true, globally unbind the key.
* `multishell-activate-command-key' - Set this to get the binding or not.
* `multishell-command-key' - The key to use for the binding, if appropriate."
- (cond (unbind
- (when (and (boundp 'multishell-command-key) multishell-command-key)
- (global-unset-key multishell-command-key)))
- ((not (and (boundp 'multishell-activate-command-key)
- (boundp 'multishell-command-key)))
- nil)
- ((and multishell-activate-command-key multishell-command-key)
- (setq multishell--responsible-for-command-key t)
- (global-set-key multishell-command-key 'multishell-pop-to-shell))))
+ (when (bound-and-true-p multishell-command-key)
+ (if unbind
+ (global-unset-key multishell-command-key)
+ (when (bound-and-true-p multishell-activate-command-key)
+ (setq multishell--responsible-for-command-key t)
+ (global-set-key multishell-command-key 'multishell-pop-to-shell)))))
(defcustom multishell-activate-command-key nil
"Set this to impose the `multishell-command-key' binding.
-You can instead manually bind `multishell-pop-to-shell` using emacs
-lisp, eg: (global-set-key \"\\M- \" 'multishell-pop-to-shell)."
+You can instead manually bind `multishell-pop-to-shell' using emacs
+lisp, eg: (global-set-key \"\\M- \" \\='multishell-pop-to-shell)."
:type 'boolean
- :set 'multishell-activate-command-key-setter)
+ :set #'multishell-activate-command-key-setter)
;; Implement the key customization whenever the package is loaded:
(if (fboundp 'with-eval-after-load)
(with-eval-after-load "multishell"
- (multishell-implement-command-key-choice))
+ (multishell-implement-command-key-choice))
(eval-after-load "multishell"
'(multishell-implement-command-key-choice)))
- [elpa] branch externals/multishell created (now 35a0dd3), Stefan Monnier, 2020/11/29
- [elpa] externals/multishell b314574 01/23: multishell-start-shell-in-buffer: be tolerant of absent remote dirs.xo, Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 6d77e93 02/23: Increment version number., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 708bad6 03/23: Forward compatibility: cl-progv rather than progv, Stefan Monnier, 2020/11/29
- [elpa] externals/multishell c39be89 04/23: Increment version to 1.1.7 and copyright span to include current year., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell bf8c445 05/23: Use appropriate interactive mode., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell ee12b22 08/23: Unravel conditional tangle (and use bound-and-true-p),
Stefan Monnier <=
- [elpa] externals/multishell 6b0bc33 12/23: Rectify code formatting, per gnu people's guidance., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell aae3f1e 06/23: Use dolist instead of mapcar., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 5adbb49 09/23: Remove unused variable., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 2b4d9d7 15/23: Rectify code formatting, per gnu people's guidance., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 0d349ee 16/23: Revise in-file change log acknowledging other's work and prior unreleased, Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 9d23005 17/23: Refine multishell-pop-to-shell docstring., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell e26492d 18/23: Refine multishell-pop-to-shell docstring a bit more., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 84a7a57 19/23: Minor wording in acknowledgment., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 8026840 10/23: Change variable name to respect gnu conventions., Stefan Monnier, 2020/11/29
- [elpa] externals/multishell 68493fa 11/23: Include lexical binding and adjust header copyright date., Stefan Monnier, 2020/11/29