On Mon, Apr 02 2012, Albin Stjerna <[email protected]> wrote:
> I have a number of functions in my Emacs config to add standard tags to 
> emails in notmuch. Since a recent upgrade of notmuch on debian testing 
> (current version 0.12, not sure what the older version was), these functions 
> no longer seem to work. For example, running this function:
>
> (defun notmuch-show-read/review ()
>   (interactive)
>   (notmuch-show-add-tag "read/review")
>   (notmuch-show-archive-thread))
>
> will produce the following error:
>
> notmuch-show-read/review: Wrong number of arguments: #[nil "ÀÁ!‡" 
> [notmuch-show-tag "+"] 2 
> ("/usr/share/emacs-snapshot/site-lisp/notmuch/notmuch-show.elc" . 53071) 
> nil], 1
>
> What has changed, and what can I do to fix this problem? The docstrings for 
> the functions I use doesn't really give any clues.

Hi, Albin.  Yes, there were some recent changes to how tagging is
handled that has caused a bit of confusion.  I think we might also need
to tweak it a bit more to get it right.  Sorry you ran into trouble.

However, in the mean time, I think you will need to modify your function
as such:

(defun notmuch-show-read/review ()
  (interactive)
  (notmuch-show-tag-message "+read/review")
  (notmuch-show-archive-thread))

Note the new tagging function is notmuch-show-tag-message, and the
tagging operation has to include the sign.

I think this interface can be cleaned up considerably, and I have some
ideas how (based on improvements I just submitted for search-mode [0]).

[0] id:"[email protected]"

Note, there are also now a suite of show-mode archiving functions,
depending on your needs:

  notmuch-show-archive-thread
  notmuch-show-archive-thread-then-next
  notmuch-show-archive-thread-then-exit
  notmuch-show-archive-message
  notmuch-show-archive-message-then-next-or-exit
  notmuch-show-archive-message-then-next-or-next-thread

hth, and good luck.

jamie.

Attachment: pgpjf0L4TdPQd.pgp
Description: PGP signature

_______________________________________________
notmuch mailing list
[email protected]
http://notmuchmail.org/mailman/listinfo/notmuch

Reply via email to