]> git.notmuchmail.org Git - notmuch/blobdiff - emacs/notmuch-hello.el
emacs: renamed function notmuch-version to notmuch-cli-version
[notmuch] / emacs / notmuch-hello.el
index 3de52386e86ba713575b66b7d81fc75dd177e7cc..7bfa752d2a04d3d3cc0244aac63299979fb9a88e 100644 (file)
@@ -85,6 +85,7 @@ searches so they still work in customize."
                (group :format "%v" :inline t (const :format "  Query: " :query) (string :format "%v")))
          (checklist :inline t
                     :format "%v"
                (group :format "%v" :inline t (const :format "  Query: " :query) (string :format "%v")))
          (checklist :inline t
                     :format "%v"
+                    (group :format "%v" :inline t (const :format "Shortcut key: " :key) (key-sequence :format "%v"))
                     (group :format "%v" :inline t (const :format "Count-Query: " :count-query) (string :format "%v"))
                     (group :format "%v" :inline t (const :format "" :sort-order)
                            (choice :tag " Sort Order"
                     (group :format "%v" :inline t (const :format "Count-Query: " :count-query) (string :format "%v"))
                     (group :format "%v" :inline t (const :format "" :sort-order)
                            (choice :tag " Sort Order"
@@ -92,8 +93,13 @@ searches so they still work in customize."
                                    (const :tag "Oldest-first" oldest-first)
                                    (const :tag "Newest-first" newest-first))))))
 
                                    (const :tag "Oldest-first" oldest-first)
                                    (const :tag "Newest-first" newest-first))))))
 
-(defcustom notmuch-saved-searches '((:name "inbox" :query "tag:inbox")
-                                   (:name "unread" :query "tag:unread"))
+(defcustom notmuch-saved-searches
+  `((:name "inbox" :query "tag:inbox" :key ,(kbd "i"))
+    (:name "unread" :query "tag:unread" :key ,(kbd "u"))
+    (:name "flagged" :query "tag:flagged" :key ,(kbd "f"))
+    (:name "sent" :query "tag:sent" :key ,(kbd "t"))
+    (:name "drafts" :query "tag:draft" :key ,(kbd "d"))
+    (:name "all mail" :query "*" :key ,(kbd "a")))
   "A list of saved searches to display.
 
 The saved search can be given in 3 forms. The preferred way is as
   "A list of saved searches to display.
 
 The saved search can be given in 3 forms. The preferred way is as
@@ -101,6 +107,7 @@ a plist. Supported properties are
 
   :name            Name of the search (required).
   :query           Search to run (required).
 
   :name            Name of the search (required).
   :query           Search to run (required).
+  :key             Optional shortcut key for `notmuch-jump-search'.
   :count-query     Optional extra query to generate the count
                    shown. If not present then the :query property
                    is used.
   :count-query     Optional extra query to generate the count
                    shown. If not present then the :query property
                    is used.
@@ -621,7 +628,7 @@ with `notmuch-hello-query-counts'."
 (defun notmuch-hello-versions ()
   "Display the notmuch version(s)"
   (interactive)
 (defun notmuch-hello-versions ()
   "Display the notmuch version(s)"
   (interactive)
-  (let ((notmuch-cli-version (notmuch-version)))
+  (let ((notmuch-cli-version (notmuch-cli-version)))
     (message "notmuch version %s"
             (if (string= notmuch-emacs-version notmuch-cli-version)
                 notmuch-cli-version
     (message "notmuch version %s"
             (if (string= notmuch-emacs-version notmuch-cli-version)
                 notmuch-cli-version