From: "Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 72735@debbugs.gnu.org
Subject: bug#72735: 31.0.50; [PATCH] Make more bug-reference variables customizeable
Date: Tue, 20 Aug 2024 22:39:18 +0300 [thread overview]
Message-ID: <49562.951205165$1724182845@news.gmane.org> (raw)
In-Reply-To: <86wmkbujh5.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 20 Aug 2024 21:39:34 +0300")
Eli Zaretskii <eliz@gnu.org> writes:
>> Date: Tue, 20 Aug 2024 18:34:38 +0300
>> From: Björn Bidar via "Bug reports for GNU Emacs,
>> the Swiss army knife of text editors" <bug-gnu-emacs@gnu.org>
>>
>> I noticed that some of the variables that can be modified
>> by the user or as mentioned as such were not defined as custom variable.
>> These patches to so and correct the group of one of the existing
>> defcustom.
>>
>> The patches don't change any of the existing functionality
>> but only document these variables better and make them easier to modify.
>> Because of that I set version to Emacs 30.1. Please tell if that's ok.
>
> The emacs-30 release branch is closed to enhancements, it only
> receives bugfix changes and improvements in documentation. Converting
> a defvar to a defcustom is not just a documentation change, it
> radically changes how the variable is initialized and set. So this is
> not appropriate for the release branch.
OK I wasn't aware that there's such a difference for existing user that
don't use defcustom.
> Please see several comments below.
>
>> * lisp/progmodes/bug-reference.el (bug-reference-url-format): Define as
>> custom type. The manual and the documentation string talk like the
> ^^
>> variable like is a custom variable. It does make sense to define
> ^^
> Our convention is to leave two spaces between sentences in comments,
> strings, and commit log messages. There are several places in the
> patch where you left only one space.
Will fix, in prior changes to the file there were changes with only one space.
>> -(defvar bug-reference-url-format nil
>> +(defcustom bug-reference-url-format nil
>> "Format used to turn a bug number into a URL.
>
> I wonder how this makes sense as a defcustom, since this variable must
> be file-local, AFAIU. In any case, the doc string should explain the
> semantics of the nil value.
The doc string says it must be local however I see no reason to not be
able to have a global function that returns a default if no setting is
found for the file. E.g. it's common to have something like
keyword#bugnumber where each keyword would refer to a different
bugtracker.
>> + :group 'bug-reference)
>
> This is redundant (here and elsewhere in the patches), since the
> package name will supply the group.
ok,.
>> +FORGE-TYPE is the type of the forge, e.g., gitlab, gitea,
>> +sourcehut, or github.
>
> This leaves it unsaid how these symbols are used, and what symbols are
> recognized.
Does the original text not say that already? The choices over all the
existing symbols which are accepted, if it doesn't make sense to
e.g. add a custom symbol to extend the mode than removing the (symbol)
choice is good.
> Finally, I think this warrants a NEWS entry.
Should the news entry explain similarly that the variables can be set
with defcustom and have improved documentation?
> Thanks.
next prev parent reply other threads:[~2024-08-20 19:39 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <874j7fnr75.fsf@>
2024-08-20 17:40 ` bug#72735: 31.0.50; [PATCH] Make more bug-reference variables customizeable Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-20 17:40 ` Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-20 18:39 ` Eli Zaretskii
2024-08-20 19:39 ` Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors [this message]
[not found] ` <875xrvhtll.fsf@>
2024-08-21 13:27 ` Eli Zaretskii
[not found] <87a5h7hz3d.fsf@>
2024-08-20 19:04 ` Eli Zaretskii
2024-08-20 19:49 ` Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors
2024-08-21 5:20 ` Tassilo Horn
2024-08-21 13:51 ` Eli Zaretskii
2024-08-20 15:34 Björn Bidar via Bug reports for GNU Emacs, the Swiss army knife of text editors
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='49562.951205165$1724182845@news.gmane.org' \
--to=bug-gnu-emacs@gnu.org \
--cc=72735@debbugs.gnu.org \
--cc=bjorn.bidar@thaodan.de \
--cc=eliz@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).