GNU bug report logs - #16214
Consistency in dired-, occur-, and grep-mode

Previous Next

Package: emacs;

Reported by: Tak Kunihiro <tkk <at> misasa.okayama-u.ac.jp>

Date: Sat, 21 Dec 2013 18:21:03 UTC

Severity: wishlist

Tags: wontfix

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #78 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Howard Melman <hmelman <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Re: bug#16214: Consistency in dired-, occur-, and grep-mode
Date: Thu, 17 Feb 2022 11:28:59 -0500
I wish this got more traction so here's a small concrete proposal.

I think in all three RET already opens the file or line
under point (in dired changing the current window, in grep
and occur in another window, at least for me on the macport
of Emacs 27.2).  No changes here.

With this one change, o in any of them will open the thing
in another window and select that window:

    (define-key compilation-minor-mode-map (kbd "o") #'compile-goto-error)

C-o in all three already opens the thing in another window
but not select it, no changes here.

I propose no change to C-x C-q in any of the modes, some
want just to toggle read-only, dired already enters wdired.

This makes e enter a writable version of all three modes.
Reserve e in grep-mode (it's already unbound) for a writable
version like wdired or occur-edit via a comment or
documentation, no code change, no need to mention wgrep in
emacs proper.  The wgrep package or users can perhaps bind e
to wgrep-change-to-wgrep-mode.  Make one incompatible change
to dired:

    (define-key dired-mode-map (kbd "e") #'dired-toggle-read-only)

Dired users with existing muscle memory to enter wdired via
C-x C-q are unchanged.  Dired users that use f or RET to
edit a file are unchanged; those that use e to edit a file
will have to change or bind this themselves.  The emacs
manual already documents using f to find a file from dired
and describes RET and e, in that order, as duplicates of f.
With this, e will change to be a duplicate of C-x C-q.

In all three you use C-c C-c to apply the edits, no changes
here.

That's it.  1 comment, 1 new binding and 1 changed binding
that already has two other equally convenient (single key)
and intuitive bindings. This would make RET, o, C-o, and e
consistent in all three as well as saving changes via C-c
C-c.  I think this will be much easier for new and existing
users to remember.

-- 

Howard





This bug report was last modified 3 years and 90 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.