Remove non-directories from rollback slot list
Addressing #4586. The bug stops Spacemacs from listing rollback slots if there exists a file (i.e. non-directory) in the rollback directory. e.g. .emacs.d/.cache/.rollback/.DS_Store (common in OS X)
This commit is contained in:
parent
7b06611cdb
commit
23525a3d1d
|
@ -996,7 +996,8 @@ If called with a prefix argument ALWAYS-UPDATE, assume yes to update."
|
||||||
(reverse
|
(reverse
|
||||||
(delq nil (mapcar
|
(delq nil (mapcar
|
||||||
(lambda (x)
|
(lambda (x)
|
||||||
(when (not (or (string= "." x) (string= ".." x)))
|
(when (and (file-directory-p (concat rolldir x))
|
||||||
|
(not (or (string= "." x) (string= ".." x))))
|
||||||
(let ((p (length (directory-files (file-name-as-directory
|
(let ((p (length (directory-files (file-name-as-directory
|
||||||
(concat rolldir x))))))
|
(concat rolldir x))))))
|
||||||
;; -3 for . .. and rollback-info
|
;; -3 for . .. and rollback-info
|
||||||
|
|
Loading…
Reference in a new issue