;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; ;; my/mailcheck.el ;; (defun my/mailcheck () "show unread mails if any" (interactive) (shell-command-to-string "mbsync sakura") (shell-command-to-string "notmuch new") (setq mails (substring (shell-command-to-string "notmuch count tag:unread") 0 -1)) (if (equal "0" mails) (message "No mail") (notmuch-search "tag:unread") (message "%s unread" mails) ) )