-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Closed
Labels
is:featureAdds or requests new features, or extends existing onesAdds or requests new features, or extends existing onesmodule:emacs/diredPertains to Doom's :emacs dired modulePertains to Doom's :emacs dired modulestatus:resolvedIssue was addressed internallyIssue was addressed internally
Description
By default using RET to navigate directories in dired leaves a lot of buffer pollution. Every RET command creates a new dired buffer which is rarely desirable. There's even an entire wiki page devoted to disabling this annoying behavior: https://www.emacswiki.org/emacs/DiredReuseDirectoryBuffer
The most convincing approach for how to do this seems to be Xah Lee's:
(define-key dired-mode-map (kbd "RET") 'dired-find-alternate-file) ; was dired-find-file
(define-key dired-mode-map (kbd "^") (lambda () (interactive) (find-alternate-file ".."))) ; was dired-up-directory
We just remap the offending commands into their non offending versions.
Metadata
Metadata
Assignees
Labels
is:featureAdds or requests new features, or extends existing onesAdds or requests new features, or extends existing onesmodule:emacs/diredPertains to Doom's :emacs dired modulePertains to Doom's :emacs dired modulestatus:resolvedIssue was addressed internallyIssue was addressed internally