Re: [PATCH 1/1] emacs: Make notmuch-show-next-thread return nil on failure

Subject: Re: [PATCH 1/1] emacs: Make notmuch-show-next-thread return nil on failure

Date: Fri, 29 Apr 2022 16:59:39 +0300

To: Leo, notmuch@notmuchmail.org

Cc: Leo Okawa Ericson

From: Tomi Ollila


On Thu, Apr 28 2022, Leo wrote:

> From: Leo Okawa Ericson <git@relevant-information.com>
>
> Having notmuch-show-next-thread return non-nil on success and nil on
> failure makes it easier for users to interact with notmuch via elisp.
> ---
>  emacs/notmuch.el | 17 +++++++++--------
>  1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/emacs/notmuch.el b/emacs/notmuch.el
> index c9cf80dc..a6198f4e 100644
> --- a/emacs/notmuch.el
> +++ b/emacs/notmuch.el
> @@ -525,14 +525,15 @@ (defun notmuch-search-show-thread (&optional elide-toggle)
>    (let ((thread-id (notmuch-search-find-thread-id)))
>      (if thread-id
>  	(notmuch-show thread-id
> -		      elide-toggle
> -		      (current-buffer)
> -		      notmuch-search-query-string
> -		      ;; Name the buffer based on the subject.
> -		      (format "*%s*" (truncate-string-to-width
> -				      (notmuch-search-find-subject)
> -				      30 nil nil t)))
> -      (message "End of search results."))))
> +	       elide-toggle

I don't see why this indentation change is happening...

> +	       (current-buffer)
> +	       notmuch-search-query-string
> +	       ;; Name the buffer based on the subject.
> +	       (format "*%s*" (truncate-string-to-width
> +			       (notmuch-search-find-subject)
> +			       30 nil nil t)))
> +      (message "End of search results.")
> +      nil)))
>  
>  (defun notmuch-tree-from-search-current-query ()
>    "Tree view of current query."
> -- 
> 2.36.0
>
> _______________________________________________
> notmuch mailing list -- notmuch@notmuchmail.org
> To unsubscribe send an email to notmuch-leave@notmuchmail.org
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: