mirror of https://github.com/djcb/mu.git
support recursive maildirs
This commit is contained in:
parent
84477bc88a
commit
0fa6a92bb3
|
@ -245,7 +245,6 @@ Function will return the cdr of the list element."
|
||||||
(cdr chosen)
|
(cdr chosen)
|
||||||
(mu4e-warn "Unknown shortcut '%c'" response))))
|
(mu4e-warn "Unknown shortcut '%c'" response))))
|
||||||
|
|
||||||
|
|
||||||
(defun mu4e~get-maildirs-1 (path mdir)
|
(defun mu4e~get-maildirs-1 (path mdir)
|
||||||
"Get maildirs under path, recursively, as a list of relative paths."
|
"Get maildirs under path, recursively, as a list of relative paths."
|
||||||
(let ((dirs)
|
(let ((dirs)
|
||||||
|
@ -258,8 +257,11 @@ Function will return the cdr of the list element."
|
||||||
(when (and (booleanp (cadr dentry)) (cadr dentry))
|
(when (and (booleanp (cadr dentry)) (cadr dentry))
|
||||||
(if (file-accessible-directory-p
|
(if (file-accessible-directory-p
|
||||||
(concat mu4e-maildir "/" mdir "/" (car dentry) "/cur"))
|
(concat mu4e-maildir "/" mdir "/" (car dentry) "/cur"))
|
||||||
(setq dirs (cons (concat mdir (car dentry)) dirs))
|
(setq dirs (cons (concat mdir (car dentry)) dirs)))
|
||||||
(setq dirs (append dirs (mu4e~get-maildirs-1 path
|
(if (not (or (string-equal "cur" (car dentry))
|
||||||
|
(string-equal "new" (car dentry))
|
||||||
|
(string-equal "tmp" (car dentry))))
|
||||||
|
(setq dirs (append dirs (mu4e~get-maildirs-1 path
|
||||||
(concat mdir (car dentry) "/")))))))
|
(concat mdir (car dentry) "/")))))))
|
||||||
dirs))
|
dirs))
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue