[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master 7b91a39 60/90: ivy.el (ivy-kill-line): Add and bind to "C-
From: |
Oleh Krehel |
Subject: |
[elpa] master 7b91a39 60/90: ivy.el (ivy-kill-line): Add and bind to "C-k" |
Date: |
Tue, 30 Jun 2015 07:28:45 +0000 |
branch: master
commit 7b91a3917da38fcc2e340e21505784254d16ba69
Author: Oleh Krehel <address@hidden>
Commit: Oleh Krehel <address@hidden>
ivy.el (ivy-kill-line): Add and bind to "C-k"
The only difference to `kill-line' is that it will kill the whole input
when at the end of the minibuffer. In that case, the regular `kill-line'
was extending into the second line of the minibuffer, which is
unacceptable.
---
ivy.el | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)
diff --git a/ivy.el b/ivy.el
index 4facc63..377fed3 100644
--- a/ivy.el
+++ b/ivy.el
@@ -124,6 +124,7 @@ Only \"./\" and \"../\" apply here. They appear in reverse
order."
(define-key map (kbd "M-j") 'ivy-yank-word)
(define-key map (kbd "M-i") 'ivy-insert-current)
(define-key map (kbd "C-o") 'hydra-ivy/body)
+ (define-key map (kbd "C-k") 'ivy-kill-line)
map)
"Keymap used in the minibuffer.")
(autoload 'hydra-ivy/body "ivy-hydra" "" t)
@@ -589,6 +590,13 @@ On error (read-only), call `ivy-on-del-error-function'."
(unless (= (point) (line-end-position))
(kill-word arg)))
+(defun ivy-kill-line ()
+ "Forward to `kill-line'."
+ (interactive)
+ (if (eolp)
+ (kill-region (minibuffer-prompt-end) (point))
+ (kill-line)))
+
(defun ivy-backward-kill-word ()
"Forward to `backward-kill-word'."
(interactive)
- [elpa] master 61bb9e0 50/90: Require TRAMP in time, (continued)
- [elpa] master 61bb9e0 50/90: Require TRAMP in time, Oleh Krehel, 2015/06/30
- [elpa] master 9df660c 51/90: swiper.el (swiper-query-replace): Don't miss the first, Oleh Krehel, 2015/06/30
- [elpa] master d47dd9b 52/90: ivy-hydra.el: Improve for hydra not installed, Oleh Krehel, 2015/06/30
- [elpa] master 265f47d 53/90: Swiper should not deactivate-mark, Oleh Krehel, 2015/06/30
- [elpa] master 4cdb80c 54/90: ivy-hydra.el (defhydra): Wrap in eval-when-compile, Oleh Krehel, 2015/06/30
- [elpa] master 1dbdcdc 55/90: counsel.el (counsel-M-x): Fixup, Oleh Krehel, 2015/06/30
- [elpa] master bcc5f45 56/90: counsel.el (counsel-M-x): Fixup smex interaction, Oleh Krehel, 2015/06/30
- [elpa] master e238286 57/90: "M-n", "M-p", "M-i" should switch directories when needed, Oleh Krehel, 2015/06/30
- [elpa] master 3f41ce6 58/90: Put the file instead of partial input on history, Oleh Krehel, 2015/06/30
- [elpa] master 5e3c635 59/90: Add a set of commands for resizing minibuffer height, Oleh Krehel, 2015/06/30
- [elpa] master 7b91a39 60/90: ivy.el (ivy-kill-line): Add and bind to "C-k",
Oleh Krehel <=
- [elpa] master dcf0f64 61/90: Add "^" as initial input to "C-h f" and "C-h v", Oleh Krehel, 2015/06/30
- [elpa] master 1ef7e18 62/90: "M-i" should not switch directories, Oleh Krehel, 2015/06/30
- [elpa] master 46695ac 63/90: Fix non-file completions ability to enter tramp completion, Oleh Krehel, 2015/06/30
- [elpa] master a5e49ff 64/90: Make counsel-M-x respect ivy-format-function, Oleh Krehel, 2015/06/30
- [elpa] master 5fcdfb4 65/90: Add better positioning to counsel-git-grep finalizer, Oleh Krehel, 2015/06/30
- [elpa] master 581d8c0 66/90: Don't cut off "/ssh:foo" input, Oleh Krehel, 2015/06/30
- [elpa] master 513a77e 67/90: ivy.el (ivy-alt-done): Find file if given a full tramp path, Oleh Krehel, 2015/06/30
- [elpa] master 972036c 68/90: ivy.el (ivy-alt-done): Enable recursive minibuffers, Oleh Krehel, 2015/06/30
- [elpa] master d9c4427 69/90: Improve performance for "^" initial input, Oleh Krehel, 2015/06/30
- [elpa] master 2c8ad2a 70/90: Add support for Windows drive letters, Oleh Krehel, 2015/06/30