GNU bug report logs - #44202
[PATCH] Add variable to control confirmation of help-mode-revert-buffer

Previous Next

Package: emacs;

Reported by: Kevin Foley <kevin <at> kevinjfoley.me>

Date: Sat, 24 Oct 2020 23:13:01 UTC

Severity: normal

Tags: fixed, patch

Fixed in version 28.1

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

Bug is archived. No further changes may be made.

Full log


Message #23 received at 44202 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Kevin Foley <kevin <at> kevinjfoley.me>
Cc: Stefan Kangas <stefan <at> marxist.se>, Drew Adams <drew.adams <at> oracle.com>,
 44202 <at> debbugs.gnu.org
Subject: Re: bug#44202: [PATCH] Add variable to control confirmation of
 help-mode-revert-buffer
Date: Sun, 25 Oct 2020 17:50:51 +0100
Kevin Foley <kevin <at> kevinjfoley.me> writes:

> I was trying to match the noconfirm argument of the revert function but
> I agree, `help-mode-revert-buffer-confirm' is less confusing.
>
> I've attached an updated patch.

Thanks.

Looking at the code a bit more, I found it a bit odd that there'd be a
need for this since there are other mechanisms to control this in
general -- revert-without-query, in particular:

---
Optional second argument NOCONFIRM means don't ask for confirmation
at all.  (The variable `revert-without-query' offers another way to
revert buffers without querying for confirmation.)
---

But the problem is that revert-buffer calls help-mode-revert-buffer,
which doesn't heed that variable.

Now, the documentation for revert-without-query says that it's about
reverting files, so on one level that makes sense since the help buffers
don't visit files.

But...  I think it would be helpful if help-mode-revert-buffer (and
other similar functions) did heed that variable -- then there'd be one
simple way to control all this.  Or even perhaps have revert-buffer look
at that variable and do the right thing instead of punting to
revert-buffer--default.

That is, it would look at file names for buffers visiting files, and
buffer names for other buffers.

Any opinions?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 4 years and 177 days ago.

Previous Next


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