GNU bug report logs -
#58487
[PATCH] Allow filtering what items are added to Ecomplete
Previous Next
Reported by: Philip Kaludercic <philipk <at> posteo.net>
Date: Thu, 13 Oct 2022 10:07:02 UTC
Severity: wishlist
Tags: patch
Done: Philip Kaludercic <philipk <at> posteo.net>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your message dated Fri, 14 Oct 2022 18:13:41 +0000
with message-id <87zgdy6zoq.fsf <at> posteo.net>
and subject line Re: bug#58487: [PATCH] Allow filtering what items are added to Ecomplete
has caused the debbugs.gnu.org bug report #58487,
regarding [PATCH] Allow filtering what items are added to Ecomplete
to be marked as done.
(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)
--
58487: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=58487
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
[Message part 3 (text/plain, inline)]
Tags: patch
I've had this as a customisation in my local .emacs file, implemented as
advice around ecomplete-add-item:
--8<---------------cut here---------------start------------->8---
(define-advice ecomplete-add-item (:around (oldfun type key text))
"Filter out common pseudo addresses from the database.
OLDFUN is `ecomplete-add-item', passed by `advice-add', that will
be invoked with TYPE, KEY and TEXT if KEY doesn't match a known
address I don't care about."
(unless (string-match-p
(rx (or (: "@noreply.github.com" eos)
(: "@reply.github.com" eos)
(: bos "notifications <at> github.com" eos)
(: "@debbugs.gnu.org" eos)))
key)
(funcall oldfun type key text)))
--8<---------------cut here---------------end--------------->8---
Having this as a regular option seems preferable to me, so I'd like to
suggest it here.
In GNU Emacs 29.0.50 (build 5, x86_64-pc-linux-gnu, GTK+ Version
3.24.34, cairo version 1.17.6) of 2022-10-13 built on rhea
Repository revision: 0b170c6caeeb669df3cf97c54c43da9cf77e6b42
Repository branch: master
System Description: Fedora Linux 36 (Workstation Edition)
Configured using:
'configure --with-pgtk --with-imagemagick'
[0001-Allow-filtering-what-items-are-added-to-Ecomplete.patch (text/patch, attachment)]
[Message part 5 (message/rfc822, inline)]
Lars Ingebrigtsen <larsi <at> gnus.org> writes:
> Philip Kaludercic <philipk <at> posteo.net> writes:
>
>> * lisp/ecomplete.el (ecomplete-filter-regexp): Add new option.
>> (ecomplete-add-item): Respect new option.
>
> Makes sense to me; please go ahead and push.
Done
This bug report was last modified 2 years and 272 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.