From: Tino Calancha <tino.calancha@gmail.com>
To: Emacs developers <emacs-devel@gnu.org>
Cc: Christopher Genovese <genovese@cmu.edu>, tino.calancha@gmail.com
Subject: [QUESTION] Update Ibuffer keybindings
Date: Tue, 20 Dec 2016 18:10:00 +0900 [thread overview]
Message-ID: <874m1zm0ev.fsf@gmail.com> (raw)
Hi,
commit 35aaa6b6aa adds several commands to ibuffer.
You can find the entire discussion on:
https://lists.gnu.org/archive/html/emacs-devel/2016-11/msg00399.html
Chris is suggesting to go an step further and update the Ibuffer
keybindings as follows:
1) Bind the new command `ibuffer-filter-chosen-by-completion' to
'/ TAB'. Those keys together with '/ t' are currently bound to
`ibuffer-exchange-filters'.
2) Bind the new command `ibuffer-filter-by-directory' to '/ /';
rebind `ibuffer-filter-disable', which is currently bound to
'/ /', to '/ DEL'.
Please, let me know your opinion about the convenice/unconvenience
on this proposal.
Following is the patch:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
From ae5137a907071cbafafdf651c4873eac8acab141 Mon Sep 17 00:00:00 2001
From: Christopher Genovese <genovese@cmu.edu>
Date: Tue, 20 Dec 2016 17:42:24 +0900
Subject: [PATCH] ibuffer: Update key bindings
* lisp/ibuffer.el (ibuffer-mode-map): Bind 'ibuffer-filter-by-directory'
and 'ibuffer-filter-chosen-by-completion' to '//' and '/TAB' respectively.
Rebind 'ibuffer-filter-disable' to '/ DEL'.
; * etc/NEWS: Update NEWS entries.
---
etc/NEWS | 10 ++++++----
lisp/ibuffer.el | 5 +++--
2 files changed, 9 insertions(+), 6 deletions(-)
diff --git a/etc/NEWS b/etc/NEWS
index ee74236a52..5c461a7dda 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -341,12 +341,14 @@ to '/b', '/.', '//', '/*', '/i' and '/v'.
---
*** Two new commands 'ibuffer-filter-chosen-by-completion'
-and `ibuffer-and-filter', the second bound to '/&'.
+and `ibuffer-and-filter'; bound to '/ TAB' and '/&'
+respectively.
---
-*** The commands `ibuffer-pop-filter', `ibuffer-pop-filter-group',
-`ibuffer-or-filter' and `ibuffer-filter-disable' have the alternative
-bindings '/<up>', '/S-<up>', '/|' and '/DEL', respectively.
+*** The key binding for `ibuffer-filter-disable' has being changed
+to '/DEL'; the commands `ibuffer-pop-filter', `ibuffer-pop-filter-group'
+and `ibuffer-or-filter' have the alternative bindings '/<up>', '/S-<up>'
+and '/|'.
---
*** The data format specifying filters has been extended to allow
diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el
index 5a740845bd..db9cfebfc5 100644
--- a/lisp/ibuffer.el
+++ b/lisp/ibuffer.el
@@ -526,12 +526,14 @@ ibuffer-mode-map
(define-key map (kbd "/ f") 'ibuffer-filter-by-filename)
(define-key map (kbd "/ b") 'ibuffer-filter-by-basename)
(define-key map (kbd "/ .") 'ibuffer-filter-by-file-extension)
+ (define-key map (kbd "/ /") 'ibuffer-filter-by-directory)
(define-key map (kbd "/ <") 'ibuffer-filter-by-size-lt)
(define-key map (kbd "/ >") 'ibuffer-filter-by-size-gt)
(define-key map (kbd "/ i") 'ibuffer-filter-by-modified)
(define-key map (kbd "/ v") 'ibuffer-filter-by-visiting-file)
(define-key map (kbd "/ c") 'ibuffer-filter-by-content)
(define-key map (kbd "/ e") 'ibuffer-filter-by-predicate)
+ (define-key map (kbd "/ TAB") 'ibuffer-filter-chosen-by-completion)
(define-key map (kbd "/ r") 'ibuffer-switch-to-saved-filters)
(define-key map (kbd "/ a") 'ibuffer-add-saved-filters)
@@ -542,7 +544,6 @@ ibuffer-mode-map
(define-key map (kbd "/ <up>") 'ibuffer-pop-filter)
(define-key map (kbd "/ !") 'ibuffer-negate-filter)
(define-key map (kbd "/ t") 'ibuffer-exchange-filters)
- (define-key map (kbd "/ TAB") 'ibuffer-exchange-filters)
(define-key map (kbd "/ o") 'ibuffer-or-filter)
(define-key map (kbd "/ |") 'ibuffer-or-filter)
(define-key map (kbd "/ &") 'ibuffer-and-filter)
@@ -550,7 +551,7 @@ ibuffer-mode-map
(define-key map (kbd "/ P") 'ibuffer-pop-filter-group)
(define-key map (kbd "/ S-<up>") 'ibuffer-pop-filter-group)
(define-key map (kbd "/ D") 'ibuffer-decompose-filter-group)
- (define-key map (kbd "/ /") 'ibuffer-filter-disable)
+ (define-key map (kbd "/ DEL") 'ibuffer-filter-disable)
(define-key map (kbd "M-n") 'ibuffer-forward-filter-group)
(define-key map "\t" 'ibuffer-forward-filter-group)
--
2.11.0
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
In GNU Emacs 26.0.50.1 (x86_64-pc-linux-gnu, GTK+ Version 3.22.4)
of 2016-12-20
Repository revision: 35aaa6b6aa9a2e7b42465603fb32355a009c510f
reply other threads:[~2016-12-20 9:10 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874m1zm0ev.fsf@gmail.com \
--to=tino.calancha@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=genovese@cmu.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).