guix-devel
[Top][All Lists]
Advanced

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

Re: New section to easily reference Debbugs URLs within Emacs Debbugs


From: Mekeor Melire
Subject: Re: New section to easily reference Debbugs URLs within Emacs Debbugs
Date: Mon, 25 Sep 2023 21:53:58 +0000

2023-09-25 21:27 mekeor@posteo.de:

2023-09-17 16:51 maxim.cournoyer@gmail.com:

> Hello,

Hello Maxim,

> If you use Emacs and Emacs-Debbugs, you may be interested in
> applying the settings newly documented in the 'Viewing Bugs > within > Emacs' section of the manual; see it at the bottom of info > "(guix)
> The Perfect Setup").
>
> I hope that's useful,

Thank you for sharing. The new section is very useful for me. I have
two things to feed back though.


First feedback: I think the new section should instruct to set the `bug-reference-url-format'. I.e. we should add this to the suggested
code snippet: (setq bug-reference-url-format
"https://issues.guix.gnu.org/%s";). Otherwise, the suggested code
snippet results in an error when a bug reference is clicked. See
appendix.


Second feedback: It might be nice to write regular-expressions using
the `rx' macro, but imho writing them as strings is shorter,
unobtrusive and thus preferable for average Guix users. I.e. I'd
suggest to replace the two setq-expressions of code that the new
manual section suggests, with the following S-expressions
respectively:

(setq bug-reference-bug-regexp "\\(\\b\\(?:[Bb]ug ?#?\\|[Pp]atch
?#\\|[Ff]ixes:? ?#\\|RFE ?#\\|PR
[+a-z-]+/\\)\\([0-9]+\\(?:#[0-9]+\\)?\\)\\|<https://bugs\\.gnu\\.org/\\(?2:[0-9]+\\)>\\)")

(setq debbugs-browse-url-regexp
"^https?://\\(?:bugs\\|debbugs\\|issues\\.guix\\)\\.gnu\\.org/+\\(\\(?:cgi/bugreport\\.cgi\\?bug=\\)?\\)\\(?3:[[:digit:]]+\\)$")


WDYT?


[2. application/emacs-lisp; reproduce-error.el]...

Third thought: Use #' for quoting functions consistently. Maybe do some code alignment.

Putting all three thoughts together, I'd gather this code suggestion:

Attachment: new.el
Description: application/emacs-lisp


reply via email to

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