diff options
author | Carl Worth <cworth@cworth.org> | 2009-10-30 15:12:49 -0700 |
---|---|---|
committer | Carl Worth <cworth@cworth.org> | 2009-10-30 15:12:49 -0700 |
commit | 299874ce290b5619fd4a876143ee6ba18996d92d (patch) | |
tree | 6db8c6898660b0dd1c9d9ee075d592426a9410f3 | |
parent | 17a0b8a95f3d041dd39199d3853b03f7b9fce727 (diff) |
notmuch-mode: Add an actualy notmuch-search-mode as well
Doesn't really do anything so far other than mark the buffer read-
only. This does have the benefit of giving us our own name rather
than "Compilation" for the mode.
-rw-r--r-- | notmuch-mode.el | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/notmuch-mode.el b/notmuch-mode.el index eec9204..450d456 100644 --- a/notmuch-mode.el +++ b/notmuch-mode.el @@ -1,7 +1,16 @@ ; A mode for running notmuch within emacs +;;;###autoload +(defun notmuch-search-mode () + "Major mode for handling the output of notmuch search" + (interactive) + (kill-all-local-variables) + (setq major-mode 'notmuch-search-mode + mode-name "notmuch-search") + (setq buffer-read-only t)) + (defun notmuch () "Run notmuch to display all mail with tag of 'inbox'" (interactive) (require 'compile) - (compilation-start "notmuch search tag:inbox")) + (compilation-start "notmuch search tag:inbox" 'notmuch-search-mode)) |