Closed ryanprior closed 4 years ago
This quick fix works for me (not really tested thoroughly):
(defun rg/all-the-icons-dired-hook ()
(setq-local all-the-icons-dired-displayed nil)
(all-the-icons-dired--display))
;;;###autoload
(define-minor-mode rg/all-the-icons-dired-mode
"Display all-the-icons icon for each files in a dired buffer."
:lighter " rg/all-the-icons-dired-mode"
(if (and (display-graphic-p) rg/all-the-icons-dired-mode)
(progn
(add-hook 'dired-after-readin-hook 'rg/all-the-icons-dired-hook t t)
(when (derived-mode-p 'dired-mode)
(all-the-icons-dired--display)))
(remove-hook 'dired-after-readin-hook 'rg/all-the-icons-dired-hook t)
(dired-revert)))
(add-hook 'dired-mode-hook 'rg/all-the-icons-dired-mode)
I think the simple workaround is:
(advice-add #'all-the-icons-dired--display :before #'all-the-icons-dired--reset)
I refreshed my packages and find that the issue is resolved for me. I also tried it with a fresh Spacemacs install which has none of my custom init, in order to make sure I wasn't patching the behavior somewhere; it still worked fine.
So I'd consider this issue resolved. Thank you!
When inserting a subdirectory into a dired buffer, the new items don't show any icons.
Steps to reproduce
1) open a dired buffer in a directory with a subdirectory that has files in it 2) activate
all-the-icons-dired-mode
3) put the cursor over the subdirectory and hit iExpected result: icons show for files in the subdirectory Actual result: no icons show
Workaround
If you deactivate
all-the-icons-dired-mode
and re-activate it, all the items get icons including the ones in the subdirectory.