diff --git a/ChangeLog b/ChangeLog index f5684132b..f8f78d0e4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,7 @@ WeeChat ChangeLog ================= Sébastien Helleu -v0.3.8-dev, 2012-03-25 +v0.3.8-dev, 2012-03-26 Version 0.3.8 (under dev!) @@ -20,6 +20,7 @@ Version 0.3.8 (under dev!) given to plugin API functions (warning displayed if debug for plugin is >= 1) * api: add list "gui_buffer_last_displayed" in hdata "buffer" * guile: add missing function "hook_process_hashtable" in API +* irc: allow more than one nick in command /invite * irc: do not send command "MODE #channel" on manual /names (do it only when names are received on join of channel) (bug #35930) * irc: do not allow the creation of two servers with same name but different diff --git a/doc/de/autogen/user/irc_commands.txt b/doc/de/autogen/user/irc_commands.txt index d91f90260..5ff3ec877 100644 --- a/doc/de/autogen/user/irc_commands.txt +++ b/doc/de/autogen/user/irc_commands.txt @@ -194,7 +194,7 @@ Ziel: Servername [[command_irc_invite]] [command]*`invite`* Jemanden in einen Channel einladen:: ........................................ -/invite +/invite [...] [] nick: Nick welcher eingeladen werden soll channel: Channel für den die Einladung gelten soll diff --git a/doc/en/autogen/user/irc_commands.txt b/doc/en/autogen/user/irc_commands.txt index 3d13c4263..1eb23d15a 100644 --- a/doc/en/autogen/user/irc_commands.txt +++ b/doc/en/autogen/user/irc_commands.txt @@ -194,7 +194,7 @@ target: server name [[command_irc_invite]] [command]*`invite`* invite a nick on a channel:: ........................................ -/invite +/invite [...] [] nick: nick to invite channel: channel to invite diff --git a/doc/fr/autogen/user/irc_commands.txt b/doc/fr/autogen/user/irc_commands.txt index 7d91c5bbd..852072dfd 100644 --- a/doc/fr/autogen/user/irc_commands.txt +++ b/doc/fr/autogen/user/irc_commands.txt @@ -194,7 +194,7 @@ cible: nom du serveur [[command_irc_invite]] [command]*`invite`* inviter un pseudo sur un canal:: ........................................ -/invite +/invite [...] [] pseudo: pseudo à inviter canal: canal pour l'invitation diff --git a/doc/it/autogen/user/irc_commands.txt b/doc/it/autogen/user/irc_commands.txt index a66a1e37b..43229dab2 100644 --- a/doc/it/autogen/user/irc_commands.txt +++ b/doc/it/autogen/user/irc_commands.txt @@ -194,7 +194,7 @@ destinazione: nome server [[command_irc_invite]] [command]*`invite`* invita un nick su un canale:: ........................................ -/invite +/invite [...] [] nick: nick da invitare canale: canale su cui invitare diff --git a/po/cs.po b/po/cs.po index e72cec786..f83f71a30 100644 --- a/po/cs.po +++ b/po/cs.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Jiri Golembiovsky \n" "Language-Team: weechat-dev \n" @@ -4426,8 +4426,9 @@ msgstr "získat informace popisující server" msgid "invite a nick on a channel" msgstr "pozvat přezdívku na kanál" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8326,5 +8327,8 @@ msgstr "" msgid "Constants" msgstr "" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "mechanismu pro SASL autentizaci" diff --git a/po/de.po b/po/de.po index 4a6f91174..4ef7d7a0a 100644 --- a/po/de.po +++ b/po/de.po @@ -23,7 +23,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.7-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-03-13 16:36+0100\n" "Last-Translator: Nils Görs \n" "Language-Team: German \n" @@ -4784,8 +4784,9 @@ msgstr "Information über den Server abfragen" msgid "invite a nick on a channel" msgstr "Jemanden in einen Channel einladen" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8855,5 +8856,8 @@ msgstr "Type" msgid "Constants" msgstr "Konstanten" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "Vorrichtung zur SASL Authentifizierung" diff --git a/po/es.po b/po/es.po index 5dd2d1284..e1e500f42 100644 --- a/po/es.po +++ b/po/es.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Elián Hanisch \n" "Language-Team: weechat-dev \n" @@ -4613,8 +4613,9 @@ msgstr "obtener información describiendo al servidor" msgid "invite a nick on a channel" msgstr "invitar a un apodo a un canal" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8590,5 +8591,8 @@ msgstr "Tipo" msgid "Constants" msgstr "Constantes" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "mecanismo para la autenticación SASL" diff --git a/po/fr.po b/po/fr.po index 877c6a0b4..48a3f6684 100644 --- a/po/fr.po +++ b/po/fr.po @@ -21,8 +21,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" -"PO-Revision-Date: 2012-03-24 12:21+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" +"PO-Revision-Date: 2012-03-26 09:16+0200\n" "Last-Translator: Sebastien Helleu \n" "Language-Team: weechat-dev \n" "Language: French\n" @@ -4664,8 +4664,8 @@ msgstr "voir les informations décrivant le serveur" msgid "invite a nick on a channel" msgstr "inviter un pseudo sur un canal" -msgid " " -msgstr " " +msgid " [...] []" +msgstr " [...] []" msgid "" " nick: nick to invite\n" @@ -8657,6 +8657,9 @@ msgstr "Type" msgid "Constants" msgstr "Constantes" +#~ msgid " " +#~ msgstr " " + #~ msgid "" #~ "delay (in seconds) to wait for control sequence ending a bracketed paste " #~ "(\"ESC[201~\"); if the control sequence is not received and that delay is " diff --git a/po/hu.po b/po/hu.po index 6f85981e3..330367139 100644 --- a/po/hu.po +++ b/po/hu.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Andras Voroskoi \n" "Language-Team: weechat-dev \n" @@ -4012,8 +4012,8 @@ msgid "invite a nick on a channel" msgstr "felhasználó meghívása szobából" #, fuzzy -msgid " " -msgstr "név szoba" +msgid " [...] []" +msgstr "név [név...]" #, fuzzy msgid "" @@ -7847,6 +7847,10 @@ msgstr "" msgid "Constants" msgstr "" +#, fuzzy +#~ msgid " " +#~ msgstr "név szoba" + #, fuzzy #~ msgid "mechanism for SASL authentication" #~ msgstr "SSL használata a a kapcsolathoz" diff --git a/po/it.po b/po/it.po index b2af6fd7d..5008d088c 100644 --- a/po/it.po +++ b/po/it.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Marco Paolone \n" "Language-Team: weechat-dev \n" @@ -4606,8 +4606,9 @@ msgstr "ottieni informazioni sul server" msgid "invite a nick on a channel" msgstr "invita un nick su un canale" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8565,5 +8566,8 @@ msgstr "Tipo" msgid "Constants" msgstr "Costanti" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "meccanismo per l'autenticazione SASL" diff --git a/po/ja.po b/po/ja.po index 6265aff92..8189c2577 100644 --- a/po/ja.po +++ b/po/ja.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: \"AYANOKOUZI, Ryuunosuke\" \n" "Language-Team: Japanese\n" @@ -4500,8 +4500,9 @@ msgstr "サーバに関する情報を入手" msgid "invite a nick on a channel" msgstr "チャンネルにニックネームを招待" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8366,5 +8367,8 @@ msgstr "タイプ" msgid "Constants" msgstr "定数" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "SASL 認証メカニズム" diff --git a/po/pl.po b/po/pl.po index ccf408fd1..1aa28b468 100644 --- a/po/pl.po +++ b/po/pl.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Krzysztof Korościk \n" "Language-Team: weechat-dev \n" @@ -4591,8 +4591,9 @@ msgstr "pobiera informacje opisujące serwer" msgid "invite a nick on a channel" msgstr "zaprasza użytkownika na kanał" -msgid " " -msgstr " " +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" @@ -8500,5 +8501,8 @@ msgstr "Typ" msgid "Constants" msgstr "Stałe" +#~ msgid " " +#~ msgstr " " + #~ msgid "mechanism for SASL authentication" #~ msgstr "mechanizm uwierzytelniania SASL" diff --git a/po/pt_BR.po b/po/pt_BR.po index 8dfed9f93..75795a666 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Sergio Durigan Junior \n" "Language-Team: weechat-dev \n" @@ -4370,8 +4370,9 @@ msgstr "" msgid "invite a nick on a channel" msgstr "" -msgid " " -msgstr "" +#, fuzzy +msgid " [...] []" +msgstr " [...]" msgid "" " nick: nick to invite\n" diff --git a/po/ru.po b/po/ru.po index f7f5c46fc..b3fb3c78e 100644 --- a/po/ru.po +++ b/po/ru.po @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.8-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: 2012-02-26 09:16+0100\n" "Last-Translator: Aleksey V Zapparov AKA ixti \n" "Language-Team: weechat-dev \n" @@ -4042,8 +4042,8 @@ msgid "invite a nick on a channel" msgstr "пригласить ник на канал" #, fuzzy -msgid " " -msgstr "ник канал" +msgid " [...] []" +msgstr "ник [ник ...]" #, fuzzy msgid "" @@ -7866,6 +7866,10 @@ msgstr "" msgid "Constants" msgstr "" +#, fuzzy +#~ msgid " " +#~ msgstr "ник канал" + #, fuzzy #~ msgid "mechanism for SASL authentication" #~ msgstr "использовать SSL при связи с сервером" diff --git a/po/weechat.pot b/po/weechat.pot index 7edbbbadc..4fa7e5c6c 100644 --- a/po/weechat.pot +++ b/po/weechat.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2012-03-24 12:52+0100\n" +"POT-Creation-Date: 2012-03-26 13:41+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -3560,7 +3560,7 @@ msgstr "" msgid "invite a nick on a channel" msgstr "" -msgid " " +msgid " [...] []" msgstr "" msgid "" diff --git a/src/plugins/irc/irc-command.c b/src/plugins/irc/irc-command.c index 99ad9886d..6348bd800 100644 --- a/src/plugins/irc/irc-command.c +++ b/src/plugins/irc/irc-command.c @@ -1750,6 +1750,9 @@ int irc_command_invite (void *data, struct t_gui_buffer *buffer, int argc, char **argv, char **argv_eol) { + int i, arg_last_nick; + char *ptr_channel_name; + IRC_BUFFER_GET_SERVER_CHANNEL(buffer); IRC_COMMAND_CHECK_SERVER("invite", 1); @@ -1759,8 +1762,26 @@ irc_command_invite (void *data, struct t_gui_buffer *buffer, int argc, if (argc > 2) { - irc_server_sendf (ptr_server, IRC_SERVER_SEND_OUTQ_PRIO_HIGH, NULL, - "INVITE %s %s", argv[1], argv[2]); + if (irc_channel_is_channel (ptr_server, argv[argc - 1])) + { + arg_last_nick = argc - 2; + ptr_channel_name = argv[argc - 1]; + } + else + { + if (ptr_channel && (ptr_channel->type == IRC_CHANNEL_TYPE_CHANNEL)) + { + arg_last_nick = argc - 1; + ptr_channel_name = ptr_channel->name; + } + else + goto error; + } + for (i = 1; i <= arg_last_nick; i++) + { + irc_server_sendf (ptr_server, IRC_SERVER_SEND_OUTQ_PRIO_HIGH, NULL, + "INVITE %s %s", argv[i], ptr_channel_name); + } } else { @@ -1771,17 +1792,16 @@ irc_command_invite (void *data, struct t_gui_buffer *buffer, int argc, argv[1], ptr_channel->name); } else - { - weechat_printf (ptr_server->buffer, - _("%s%s: \"%s\" command can only be " - "executed in a channel buffer"), - weechat_prefix ("error"), IRC_PLUGIN_NAME, - "invite"); - return WEECHAT_RC_OK; - } - + goto error; } + return WEECHAT_RC_OK; +error: + weechat_printf (ptr_server->buffer, + _("%s%s: \"%s\" command can only be " + "executed in a channel buffer"), + weechat_prefix ("error"), IRC_PLUGIN_NAME, + "invite"); return WEECHAT_RC_OK; } @@ -5024,7 +5044,7 @@ irc_command_init () NULL, &irc_command_info, NULL); weechat_hook_command ("invite", N_("invite a nick on a channel"), - N_(" "), + N_(" [...] []"), N_(" nick: nick to invite\n" "channel: channel to invite"), "%(nicks) %(irc_server_channels)", &irc_command_invite, NULL);