From: Ian Kelling Date: Thu, 25 Jan 2018 22:37:09 +0000 (-0500) Subject: minor fixes X-Git-Url: https://iankelling.org/git/?a=commitdiff_plain;h=dbe020299a9ffc10681a84e9d635f2ff8f96bd0a;p=dot-emacs minor fixes --- diff --git a/my-init.org b/my-init.org index 6dcb7f1..d2e596f 100644 --- a/my-init.org +++ b/my-init.org @@ -1040,11 +1040,14 @@ and Ian Kelling as the name" ;; on first run mkdir -p /nocow/user/.mufsf; mu index --maildir=/nocow/user/fsfmd (defun mu-exit-wait () (interactive) - (let ((wait (= 0 (call-process "/bin/pidof" nil nil nil "mu")))) + ;; taken from the mu source + (let* ((buf (get-buffer mu4e~proc-name)) + (proc (and (buffer-live-p buf) (get-buffer-process buf)))) (mu4e-quit) ;; without sleep, we get database locked by another process error when hitting u ;; if another mu was running. - (when wait (sleep-for 0 300)))) + (if proc (sleep-for 0 1000)))) + (defun fsf-mu4e () (interactive) (unless (equal mu4e-maildir "/nocow/user/fsfmd") (mu-exit-wait)) @@ -1057,7 +1060,7 @@ and Ian Kelling as the name" user-mail-address "iank@fsf.org" mail-signature " --- +-- Ian Kelling | Senior Systems Administrator, Free Software Foundation GPG Key: B125 F60B 7B28 7FF6 A2B7 DF8F 170A F0E2 9542 95DF https://fsf.org | https://gnu.org