diff options
Diffstat (limited to 'degesch.c')
-rw-r--r-- | degesch.c | 16 |
1 files changed, 15 insertions, 1 deletions
@@ -3664,6 +3664,18 @@ handle_command_list (struct app_context *ctx, char *arguments) } static bool +handle_command_nick (struct app_context *ctx, char *arguments) +{ + if (!server_command_check (ctx, "change nickname")) + return true; + if (!*arguments) + return false; + + irc_send (ctx, "NICK %s", cut_word (&arguments)); + return true; +} + +static bool handle_command_quote (struct app_context *ctx, char *arguments) { if (!server_command_check (ctx, "quote")) @@ -3725,8 +3737,10 @@ g_command_handlers[] = { "motd", NULL, "", "" }, { "away", NULL, "", "" }, #endif + { "nick", handle_command_nick, "Change current nick", + "<nickname>" }, { "quote", handle_command_quote, "Send a raw command to the server", - "command" }, + "<command>" }, }; static bool |