dired backward/forward function
题
I'm looking for a package the browser's "back" button for dired. i.e. some way to go back to a previously visited directory.
The usecase I have in mind is to traverse deeper into a directory tree after invoking ^ to to to a parent folder.
解决方案
Use q
to just close the current window, and the last visited one will be here.
其他提示
I use a
to drill down into directories, then rebind ^
to this to go back up:
(defun my-dired-up-dir ()
"Go up a directory."
(interactive)
(let ((current-dir (dired-current-directory)))
(find-alternate-file "..")
(dired-goto-file current-dir)))
It goes up a directory and puts point on the directory you just came from (so you can a
back down if you want). Perhaps not exactly what you want since it only works on one level, but might still be useful.
不隶属于 StackOverflow