GNU bug report logs - #12396
24.2.50; [PATCH] extend usability of gnus-read-ephemeral-emacs-bug-group

Previous Next

Packages: emacs, gnus;

Reported by: Stephen Berman <stephen.berman <at> gmx.net>

Date: Sun, 9 Sep 2012 16:02:01 UTC

Severity: wishlist

Tags: patch

Found in version 24.2.50

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Juri Linkov <juri <at> jurta.org>
To: Stephen Berman <stephen.berman <at> gmx.net>
Cc: Lars Ingebrigtsen <larsi <at> gnus.org>, 12396 <at> debbugs.gnu.org
Subject: bug#12396: 24.2.50; [PATCH] extend usability of gnus-read-ephemeral-emacs-bug-group
Date: Wed, 12 Sep 2012 23:54:05 +0300
> Well, the use case that motivated my first patch is grabbing a bug
> number in the subject line of a mail or posting, so the distance
> involved is rather small.

Grabbing a bug number in the subject line is a well-defined goal,
but when I tried your latest version of `gnus-get-emacs-bug-number',
it can't get a bug number from the subject line.

> Admittedly, the extension to ChangeLogs could involve several lines
> between point and the bug number, which my patch does not take
> into account.

For ChangeLogs it could look only inside the current entry.

> Well, my second patch assumed my first patch, which changes
> g-r-e-e-b-g's signature, so the bug number isn't passed as an argument.
> However, I agree it is bad to request confirmation on clicking the
> button in this case.  This appears to argue against the change in the
> interactive spec.

Yes, there is no need to change the function signature
and no need to move its interactive spec to the function body.
You could just replace old (thing-at-point 'word)
with a call to a new function `gnus-get-emacs-bug-number'.
Replacing `read-string' with `read-number' in your patch
also makes sense.  But selecting one of several bug numbers
would be easier by supplying a list of bug numbers to `read-number'
and using e.g. `3 M-n' to select one of them (third in this example).

> (defun bug-reference-gnus-read-ephemeral-emacs-bug-group (pos)
>   "Read the bug thread in a Gnus ephemeral group."
>   (dolist (o (overlays-at pos))
>     ;; It should only be possible to have one URL overlay.
>     (let* ((url (overlay-get o 'bug-reference-url))
> 	   (num (when (string-match "http://debbugs\\.gnu\\.org/\\([0-9]+\\)$" url)
                                     ============================
This is a bad thing.  It is not your failure, it is by design of
bug-reference.el that you have to circumvent.  I think that
bug-reference.el should be improved to add a bug number to overlays
where it currently adds a bug URL.




This bug report was last modified 12 years and 229 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.