Run slash command sequences after IRC registration

This commit is contained in:
Johannes Findeisen 2026-12-02 00:12:07 +01:00
commit b208b5b696
3 changed files with 84 additions and 37 deletions

View file

@ -56,8 +56,9 @@ real Happy irc9 User
# Libera and OFTC use TLS on 6697. Use port 6667 without the ssl keyword for
# plain TCP. The optional sasl line applies to the server above it; the SASL
# user is your account name. An optional autocommand sends one raw IRC command
# after registration on the server above it, before startup channel joins.
# user is your account name. An optional autocommand runs after registration on
# the server above it, before startup channel joins. Separate slash commands with
# commas. irc9 waits two seconds between commands.
# libera
server irc.libera.chat 6697 ssl
@ -65,7 +66,7 @@ name Libera Chat
# Suppress incoming messages from these nicknames on this server.
# blacklist user1,user2,user3
# sasl irc9user my-sasl-password
# autocommand /msg NickServ IDENTIFY irc9user $PASSWORD
# autocommand /query user1,/query user2
# Build with make -B AUTOJOIN=1 and uncomment channel lines to join at startup.
# Each channel line applies to the server above it.
# Optional comma-separated slash commands run after the channel join succeeds.
@ -102,11 +103,14 @@ TLS; use port `6697` for Libera and OFTC. A `sasl <user> <pass>` line applies to
the most recent `server` line and enables SASL PLAIN for that server only. The
SASL user is your account name (for many people this is the same as the nick).
Place an optional `autocommand <IRC command>` below the corresponding
`server` line, immediately after its `sasl` line when present. For example,
`autocommand PRIVMSG NickServ :STATUS mynick` sends that raw IRC command.
It runs once per successful registration, including reconnects, after SASL
negotiation when configured and before startup channel joins.
Place an optional `autocommand` below the corresponding `server` line,
immediately after its `sasl` line when present. For example,
`autocommand /query user1,/query user2` opens two query windows, two seconds apart.
A comma followed by a slash, with optional spaces or tabs between them, starts
the next command. The first command can also use raw IRC syntax, as in
`autocommand PRIVMSG NickServ :STATUS mynick`. Use `/raw` for later raw commands.
The sequence runs once per successful registration, including reconnects, after
SASL negotiation when configured and before startup channel joins.
To enable startup channel joins, build with `make -B AUTOJOIN=1`. Add one
`channel #name` line per channel below the corresponding `server` line.