Is there a means to reverse the date sort order in dired?
Toggling to Dired by date mode by hitting 's' orders newest to oldest, top to bottom. I would like to reverse this so I see oldest to newest top to bottom
You do not need to manually change the ls
switches for Dired, even via C-u s
.
Just use command dired-sort-menu-toggle-reverse
from library Dired Sort Menu (dired-sort-menu.el
). dired-sort-menu.el
binds it to r
in Dired, by default.
If you also use library dired-sort-menu+.el
and Dired+ then the command is rebound to |
instead (r
is for diredp-rename-this file
).
Use a prefix argument to
dired-sort-toggle-or-edit
:C-u s
. This lets you manually specify the flags you wish to pass tols
:Then make sure to include both
-t
(to sort by modification time) and-r
(to reverse the sort), e.g.