emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug#38136: [PATCH] Make gnus-group-get-new-news a non blocking threa


From: Michael Albinus
Subject: Re: bug#38136: [PATCH] Make gnus-group-get-new-news a non blocking thread
Date: Fri, 22 Nov 2019 09:30:49 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Robert Pluim <address@hidden> writes:

>     Michael> Robert, your command in preparation might change slightly
>     Michael> the scope. Instead of showing all messages for the tagged
>     Michael> bugs, it might show all messages for the bugs in the
>     Michael> current Debbugs buffer. This is more general.
>
> Hey, when did I sign up for this? :-)

I could read your mind, you know? :-)

> +(defvar debbugs-gnu-read-bugs-limit 10)

I would make it a defcustom. Maybe we need also another defconst, which
is the upper limit this user option can be. Something like 50, or 100.

> +(defun debbugs-gnu-read-current-bugs-with-gnus ()
> +  "Create a Gnus group of the messages from the currently shown bugs."
> +  (interactive)
> +  (unless (eq debbugs-gnu-mail-backend 'gnus)
> +    (error "This function only works with Gnus."))
> +  (save-excursion
> +    (let ((mbox-url (replace-regexp-in-string
> +                     ";mboxstat=yes" ""
> +                     (alist-get 'emacs gnus-bug-group-download-format-alist)
> +                     nil t))
> +          ids)
> +      (goto-char (point-min))
> +      (dotimes (i debbugs-gnu-read-bugs-limit)
> +        (push (cdr (assq 'id (tabulated-list-get-id))) ids)
> +        (forward-line 1))
> +      (setq ids (delete nil (nreverse ids)))
> +      (gnus-read-ephemeral-bug-group
> +       ids
> +       mbox-url)
> +      (debbugs-gnu-summary-mode 1))))

That works so far for me, thanks. What I'm missing is handling of merged
bugs. That is, if a bug in a line shows also merged bug numbers.

Create a bug list via (debbugs-gnu-bugs 34322) . And then compare the
Gnus buffers, created by either (debbugs-gnu-select-report) or by
(debbugs-gnu-read-current-bugs-with-gnus) .

We would need also a command debbugs-gnu-read-current-bugs and key
bindings for this. Just to be prepared for a possible
debbugs-gnu-read-current-bugs-with-rmail.

If this is too much for your limited time, commit what you have, and I
will adapt the final bits then.

>  (defun debbugs-read-tagged-bugs-with-gnus ()
>    "Create an ephemeral Gnus group of locally tagged Emacs bugs."

I believe, this one is not needed anymore. A list with locally tagged
bugs is created now easily via debbugs-gnu-tagged. And there you call
debbugs-gnu-read-current-bugs.

Thanks, and best regards, Michael.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]