unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@linkov.net>
To: Stefan Kangas <stefankangas@gmail.com>
Cc: Lars Ingebrigtsen <larsi@gnus.org>,
	42865@debbugs.gnu.org, Sean Whitton <spwhitton@spwhitton.name>
Subject: bug#42865: 28.0.50; Add new 'copy-region-quietly' defcustom
Date: Tue, 25 Aug 2020 21:40:15 +0300	[thread overview]
Message-ID: <87r1ruvab4.fsf@mail.linkov.net> (raw)
In-Reply-To: <CADwFkmkSRRM6RaHOhSZVatd5XUtvxxqkPn32a+yUAjjk1cFFsQ@mail.gmail.com> (Stefan Kangas's message of "Mon, 24 Aug 2020 12:34:19 -0700")

>> IOW, I still prefer the simplicity of such regexps as
>>
>>   (add-to-list 'inhibit-message "^Saved text until")
>>
>> and can't imagine a situation why I'd want to inhibit such message
>> for one command but not for another.
>
> One package says: "Saved text until end"
>
> Another one says: "Saved text until end... failed, retry to avoid data
> loss"

Then it could match the whole message with $ at the end.

  (add-to-list 'inhibit-message "^Saved text until end$")

> And then you have the joy when the message text changes...

The message text changes not often.  But the symbol approach is much worse
because it takes the freedom from users - in case of symbols the developers
decide whether to allow the users to inhibit messages or not.  When developers
allow to inhibit some messages by adding a new symbol to the message function,
then it takes many years until the users can start using new symbols to
inhibit messages after the next release.

OTOH, in case of regexps, the users decide what text they want to inhibit
without waiting for developers adding new symbols.

For example, in https://debbugs.gnu.org/21893#23
I needed to inhibit the message from view-end-message.
With a regexp this would be very easy:

  (add-to-list 'inhibit-message "^End of buffer")

But currently I use such complicated advice:

  (advice-add 'view-end-message :around
              (lambda (orig-fun &rest args)
                (let ((inhibit-message t))
                  (apply orig-fun args)))
              '((name . non-verbose-view-end-message)))

Also using regexps will obsolete many such ad-hoc options as
'view-inhibit-help-message'.





  reply	other threads:[~2020-08-25 18:40 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-14 17:38 bug#42865: 28.0.50; Add new 'copy-region-quietly' defcustom Sean Whitton
2020-08-18 13:37 ` Lars Ingebrigtsen
2020-08-19  1:16   ` Juri Linkov
2020-08-19 10:25     ` Lars Ingebrigtsen
2020-08-20  0:52       ` Juri Linkov
2020-08-20 13:01         ` Lars Ingebrigtsen
2020-08-20 23:19           ` Juri Linkov
2020-08-21 11:28             ` Lars Ingebrigtsen
2020-08-23 18:39               ` Juri Linkov
2020-08-24 13:14                 ` Lars Ingebrigtsen
2020-08-24 13:26                   ` Stefan Kangas
2020-08-24 14:00                     ` Lars Ingebrigtsen
2020-08-24 18:38                   ` Juri Linkov
2020-08-24 19:34                     ` Stefan Kangas
2020-08-25 18:40                       ` Juri Linkov [this message]
2020-08-26  0:36                         ` Stefan Kangas
2020-08-27 19:08                           ` Juri Linkov
2020-11-15 20:40                           ` Juri Linkov
2020-08-20  0:55       ` Juri Linkov
2020-08-20 13:05         ` Lars Ingebrigtsen
2020-11-15 20:33       ` Juri Linkov
2020-08-19 16:36     ` Sean Whitton
2020-08-19 16:32   ` Sean Whitton
2020-08-19 16:49     ` Lars Ingebrigtsen
2020-09-10 16:05       ` Sean Whitton
2020-09-11 11:57         ` Lars Ingebrigtsen
2020-09-12 21:22           ` Sean Whitton
2020-09-13 13:09             ` Lars Ingebrigtsen
2021-06-06  9:20               ` Lars Ingebrigtsen
2021-06-28  2:02                 ` Sean Whitton

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=87r1ruvab4.fsf@mail.linkov.net \
    --to=juri@linkov.net \
    --cc=42865@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=spwhitton@spwhitton.name \
    --cc=stefankangas@gmail.com \
    /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).