summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--bin/downgrade.c10
-rw-r--r--bin/man1/downgrade.16
2 files changed, 16 insertions, 0 deletions
diff --git a/bin/downgrade.c b/bin/downgrade.c
index af1b528b..871b3eb4 100644
--- a/bin/downgrade.c
+++ b/bin/downgrade.c
@@ -120,6 +120,16 @@ static void handle(char *ptr) {
 		format("NICK %s_\r\n", nick);
 	} else if (!strcmp(cmd, "001")) {
 		if (join) format("JOIN %s\r\n", join);
+	} else if (!strcmp(cmd, "005")) {
+		char *self = strsep(&ptr, " ");
+		if (!self) errx(EX_PROTOCOL, "RPL_ISUPPORT missing nick");
+		while (ptr && *ptr != ':') {
+			char *tok = strsep(&ptr, " ");
+			char *key = strsep(&tok, "=");
+			if (!strcmp(key, "BOT") && tok) {
+				format("MODE %s +%s\r\n", self, tok);
+			}
+		}
 	} else if (!strcmp(cmd, "INVITE") && invite) {
 		strsep(&ptr, " ");
 		if (!ptr) errx(EX_PROTOCOL, "INVITE missing channel");
diff --git a/bin/man1/downgrade.1 b/bin/man1/downgrade.1
index 910b42c3..e1a594b7 100644
--- a/bin/man1/downgrade.1
+++ b/bin/man1/downgrade.1
@@ -97,6 +97,12 @@ Connect to
 .Re
 .It
 .Rs
+.%A Daniel Oaks
+.%T Bot Mode
+.%U https://ircv3.net/specs/extensions/bot-mode
+.Re
+.It
+.Rs
 .%A James Wheare
 .%T Message IDs
 .%U https://ircv3.net/specs/extensions/message-ids
:09 -0400'>2024-10-12Add photos from October 6June McEnroe 2024-10-12Add photos from October 5June McEnroe 2024-10-09Add photos from October 1June McEnroe 2024-10-07Add photos from September 29June McEnroe 2024-10-07Add photos from September 28June McEnroe 2024-10-07Add photos from September 22June McEnroe 2024-09-25Add photos from September 15June McEnroe 2024-09-24Add photos from September 14June McEnroe 2024-09-24Add photos from September 12June McEnroe 2024-09-24Add photos from September 7June McEnroe 2024-09-24Allow not having descriptionsJune McEnroe 2024-09-23Automatically select the last used lens for a bodyJune McEnroe 2024-09-19Add photos from September 5June McEnroe 2024-09-15Add some more film stocks to the listJune McEnroe 2024-09-13Add photos from September 2June McEnroe 2024-09-13Add Fomapan 200 to films listJune McEnroe 2024-09-10Add August 29 picnic photosJune McEnroe 2024-09-08Apply some bold to trips renderingJune McEnroe 2024-09-08Render trips hopefully more efficientlyJune McEnroe 2024-09-08Allow removing bodies and lensesJune McEnroe 2024-09-08Limit body width so it looks less silly on desktopJune McEnroe 2024-09-07Handle no film being loadedJune McEnroe 2024-09-07Fancy up the text a littleJune McEnroe