General improvements to dired setup

parent 4b8aa3e5
......@@ -1305,14 +1305,20 @@ in
dired = {
enable = true;
defer = true;
command = [ "dired" "dired-jump" ];
config = ''
(put 'dired-find-alternate-file 'disabled nil)
;; Use the system trash can.
(setq delete-by-moving-to-trash t)
(setq dired-listing-switches "-alvh --group-directories-first")
'';
};
all-the-icons-dired = {
enable = true;
hook = [ "(dired-mode . all-the-icons-dired-mode)" ];
};
wdired = {
enable = true;
bindLocal = {
......@@ -1327,9 +1333,19 @@ in
'';
};
# Hide hidden files when opening a dired buffer. But allow showing them by
# pressing `.`.
dired-x = {
enable = true;
after = [ "dired" ];
# after = [ "dired" ];
hook = [ "(dired-mode . dired-omit-mode)" ];
bindLocal.dired-mode-map = {
"." = "dired-omit-mode";
};
config = ''
(setq dired-omit-verbose nil
dired-omit-files (concat dired-omit-files "\\|^\\..+$"))
'';
};
recentf = {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment