1

My ERC irc client sends some very annoying messages that fill most of my screen, letting me know that I've connected. I'd like to turn these off.

I've tried setting a couple of variables and functions to nil without success: I expected setq erc-enable-notifications nil to do what I needed, but alas, it isn't the right place for this.

I'm using the Spacemacs init with the ERC layer.

enter image description here These messages fill my screen every few minutes when my bouncer reconnects to me, so I suspect the repeated spam is the fault of my ZNC bouncer configuration.

  • While the repeated spam is probably my fault, the initial spam is not, and is still annoying. – Spenser Truex Jul 5 at 23:05
  • I do not have an erc-enable-notifications variable in Emacs 26.2. Where is that defined? – phils Jul 7 at 3:11
  • I am using spacemacs, this question is spacemacs-specific. – Spenser Truex Aug 24 at 23:12
  • I have a Spacemacs config sitting around, and it doesn't have an erc-enable-notifications variable either. What does C-h v erc-enable-notifications say? As ERC is part of Emacs, and Spacemacs is Emacs plus additional libraries, I doubt there is anything in this question which needs to be spacemacs-specific. – phils Aug 24 at 23:54
3

Try setting C-hv erc-track-exclude-types

For me, the original value was ("NICK" "333" "353") and I have it set to:

("JOIN" "KICK" "NICK" "PART" "QUIT" "MODE" "333" "353")

The numeric values can be specific to the IRC daemon you are connected to, and might entail trial and error on your part to figure out which values are creating noise for you.

e.g. The following file (AFAICS) defines those recognised by the undernet (ircu) server (but the names and comments are pretty cryptic for the most part):

https://github.com/UndernetIRC/ircu2/blob/master/include/numeric.h

I'd be interested in pointers to other similar lists, and to any better documentation of the values (especially ones which are effectively standard).

Things I've located just now are:

  • Ignoring numerics is the way to go for preventing spam. – Spenser Truex Nov 16 at 7:36
1

If this is on account of erc-notifications-mode generating a notification because your nick was mentioned in the channel (on account of being listed in "*** Users on ..." message), then you'll have to dig into that functionality.

Or just disable the mode with (erc-notifications-mode 0) or similar to disable all notifications.

If that's the reason, then erc-notifications-notify-on-match will be triggering the message. It looks at erc-track-exclude but I'm not sure whether erc-track-exclude-types has been factored in by that point.

The mode uses erc-text-matched-hook which is run from erc-match-message, and I'm not seeing any obvious use of the exclude-types in that sequence.

You might need to redefine or advise erc-notifications-notify-on-match to recognise and ignore these types of message.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.