       (put face 'theme-face nil)
       (face-spec-set face spec)))
 
+  (dolist (face-map '((all-the-icons-dired-dir-face . dired-directory)))
+    (let* ((face (car face-map))
+           (alias (cdr face-map)))
+      (put face 'theme-face nil)
+      (put face 'face-alias alias)))
+
   (let ((line (face-attribute 'mode-line :underline)))
     (set-face-attribute 'mode-line nil :overline line :box nil)
     (set-face-attribute 'mode-line-inactive nil :overline line :underline line :box nil))

  :bind (("C-x v M-m" . monky-status)))

;; File management
(add-hook 'dired-mode-hook
          (lambda ()
            (add-minor-mode 'dired-hide-details-mode "")
            (when (memq (window-system) '(mac ns))
              (bind-key "z" (lambda ()
                              (interactive)
                              (let ((file-name (dired-get-file-for-visit)))
                                (start-process "default-app" nil "open" file-name)))
                        dired-mode-map))))

(use-package all-the-icons-dired
  :after (all-the-icons)
  :if (display-graphic-p)
  :hook (dired-mode . all-the-icons-dired-mode))

(use-package dired-hide-dotfiles
  :bind (:map dired-mode-map

(use-package dired-single
  :after (dired-hide-dotfiles)
  :bind (:map dired-mode-map
              ("^"         . dired-single-up-directory)
              ("<mouse-1>" . dired-single-buffer-mouse)
              ("\C-m"      . dired-single-buffer))
  :config
  (with-eval-after-load 'window-purpose-x
    (setq dired-single-magic-buffer-name purpose-x-code1-dired-buffer-name))
  ;; Make sure dired-hide-details-mode is preserved when reusing the dired
  ;; window
  (advice-add 'find-alternate-file :around
