about summary refs log tree commit diff
path: root/command.c
diff options
context:
space:
mode:
Diffstat (limited to 'command.c')
-rw-r--r--command.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/command.c b/command.c
index 3af1246..199a561 100644
--- a/command.c
+++ b/command.c
@@ -159,6 +159,13 @@ static void commandAway(uint id, char *params) {
 	replies.away++;
 }
 
+static void commandSetname(uint id, char *params) {
+	(void)id;
+	if (!params) return;
+	ircFormat("SETNAME :%s\r\n", params);
+	replies.setname++;
+}
+
 static void commandTopic(uint id, char *params) {
 	if (params) {
 		ircFormat("TOPIC %s :%s\r\n", idNames[id], params);
@@ -486,6 +493,7 @@ static const struct Handler {
 	{ "/quit", commandQuit, 0 },
 	{ "/quote", commandQuote, Multiline | Restricted },
 	{ "/say", commandPrivmsg, Multiline },
+	{ "/setname", commandSetname, 0 },
 	{ "/topic", commandTopic, 0 },
 	{ "/unban", commandUnban, 0 },
 	{ "/unexcept", commandUnexcept, 0 },
mandoc on macOSJune McEnroe 2020-09-11Rewrite install script yet againJune McEnroe 2020-09-11Remove NetBSD from install scriptJune McEnroe 2020-09-11Use MacPorts rather than pkgsrcJune McEnroe 2020-09-11Add debian VM name to sshJune McEnroe 2020-09-11Add influencer tweetJune McEnroe 2020-09-10Add The Kingdom of GodsJune McEnroe 2020-09-07Add SunglassesJune McEnroe 2020-09-06Add Between the BreathsJune McEnroe 2020-09-04Open /dev/tty in nudgeJune McEnroe 2020-09-04Add nudgeJune McEnroe 2020-09-03Build fbclock with -lzJune McEnroe 2020-08-29Add tweets from retweetsJune McEnroe