summaryrefslogtreecommitdiffstats
path: root/lisp/init-dired.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/init-dired.el')
-rw-r--r--lisp/init-dired.el13
1 files changed, 13 insertions, 0 deletions
diff --git a/lisp/init-dired.el b/lisp/init-dired.el
new file mode 100644
index 0000000..01372c7
--- /dev/null
+++ b/lisp/init-dired.el
@@ -0,0 +1,13 @@
+(use-package dired
+ :ensure nil ;; package is bundled with emacs
+ :init
+ ;; show human readable sizes in dired
+ (setq dired-listing-switches "-alh")
+
+ ;; group directories first in dired if supported
+ (when (eq 0 (call-process insert-directory-program
+ nil nil nil "--group-directories-first"))
+ (setq dired-listing-switches (concat dired-listing-switches
+ " --group-directories-first"))))
+
+(provide 'init-dired)