irc: evaluate content of server option "usermode"

v2.8-utf8proc
Sébastien Helleu 2016-12-11 13:50:38 +01:00
parent 39a8b9810b
commit 36c9317077
21 changed files with 133 additions and 126 deletions

View File

@ -618,7 +618,7 @@
** Werte: on, off (Standardwert: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** Beschreibung: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>"]
** Beschreibung: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>" (note: content is evaluated, see /help eval)]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette (Standardwert: `+""+`)

View File

@ -618,7 +618,7 @@
** values: on, off (default value: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** description: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>"]
** description: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>" (note: content is evaluated, see /help eval)]
** type: string
** values: any string (default value: `+""+`)

View File

@ -618,7 +618,7 @@
** valeurs: on, off (valeur par défaut: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** description: pass:none[mode utilisateur à définir après la connexion au serveur et avant d'exécuter la commande et de rejoindre automatiquement les canaux ; cette option donne le même résultat que la définition de la commande "/mode $nick <mode>"]
** description: pass:none[mode utilisateur à définir après la connexion au serveur et avant d'exécuter la commande et de rejoindre automatiquement les canaux ; cette option donne le même résultat que la définition de la commande "/mode $nick <mode>" (note : le contenu est évalué, voir /help eval)]
** type: chaîne
** valeurs: toute chaîne (valeur par défaut: `+""+`)

View File

@ -618,7 +618,7 @@
** valori: on, off (valore predefinito: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** descrizione: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>"]
** descrizione: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>" (note: content is evaluated, see /help eval)]
** tipo: stringa
** valori: qualsiasi stringa (valore predefinito: `+""+`)

View File

@ -618,7 +618,7 @@
** 値: on, off (デフォルト値: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** 説明: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>"]
** 説明: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>" (note: content is evaluated, see /help eval)]
** タイプ: 文字列
** 値: 未制約文字列 (デフォルト値: `+""+`)

View File

@ -618,7 +618,7 @@
** wartości: on, off (domyślna wartość: `+on+`)
* [[option_irc.server_default.usermode]] *irc.server_default.usermode*
** opis: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>"]
** opis: pass:none[usermode to set after connection to server and before executing command and the auto-join of channels; this option gives same result as defining a command "/mode $nick <mode>" (note: content is evaluated, see /help eval)]
** typ: ciąg
** wartości: dowolny ciąg (domyślna wartość: `+""+`)

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:23+0200\n"
"Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -7105,6 +7105,12 @@ msgstr ""
"vlastní jméno hosta/IP pro server (nepovinné, pokud je volné použije se "
"lokální jméno hosta)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -7207,12 +7213,6 @@ msgid ""
msgstr ""
"seznam notifikací pro server (místo změny této volby použijte příkaz /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: chyba při přidávání notifikace"

View File

@ -19,7 +19,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-12-04 09:56+0100\n"
"Last-Translator: Nils Görs <weechatter@arcor.de>\n"
"Language-Team: German <kde-i18n-de@kde.org>\n"
@ -8227,6 +8227,12 @@ msgstr ""
"Server (optional). Falls kein Eintrag vorhanden sein sollte wird der lokale "
"Hostname verwendet"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -8358,12 +8364,6 @@ msgstr ""
"Liste mit Benachrichtigung für Server (diese Einstellung sollte nicht direkt "
"verändert werden. Dazu sollte der Befehl /notify genutzt werden)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: Fehler bei der Erstellung des Servers \"%s\""

View File

@ -22,7 +22,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:23+0200\n"
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -7354,6 +7354,12 @@ msgstr ""
"hostname/IP local personalizado para el servidor (opcional, si está vacío se "
"utiliza el hostname local)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -7459,12 +7465,6 @@ msgstr ""
"Lista de notificaciones para el servidor (no se debería cambiar esta opción, "
"usar el comando /notify para ello)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: error al crear el servidor \"%s\""

View File

@ -21,8 +21,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"PO-Revision-Date: 2016-12-11 13:39+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-12-11 13:49+0100\n"
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"Language: fr\n"
@ -8057,6 +8057,16 @@ msgstr ""
"nom local de machine/IP personnalisé pour le serveur (optionnel, si non "
"renseigné, le nom de machine local est utilisé)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
"mode utilisateur à définir après la connexion au serveur et avant d'exécuter "
"la commande et de rejoindre automatiquement les canaux ; cette option donne "
"le même résultat que la définition de la commande \"/mode $nick <mode>"
"\" (note : le contenu est évalué, voir /help eval)"
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -8179,15 +8189,6 @@ msgstr ""
"liste de notifications pour le serveur (vous ne devriez pas changer cette "
"option mais utiliser la commande /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
"mode utilisateur à définir après la connexion au serveur et avant d'exécuter "
"la commande et de rejoindre automatiquement les canaux ; cette option donne "
"le même résultat que la définition de la commande \"/mode $nick <mode>\""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s : erreur d'ajout du serveur \"%s\""

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:23+0200\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6551,6 +6551,12 @@ msgstr ""
"szokásos hosztnév/IP a szerveren (tetszőleges, ha üres akkor a helyi "
"hosztnevet használja)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -6645,12 +6651,6 @@ msgid ""
"command instead)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s nincs elég memória az információs pult üzenethez\n"

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:24+0200\n"
"Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -7508,6 +7508,12 @@ msgstr ""
"nome host/IP locale definito per il server (opzionale, se vuoto viene usato "
"il nome host locale)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -7611,12 +7617,6 @@ msgstr ""
"elenco notifiche per il server (si consiglia di non cambiare questa opzione "
"ma di usare il comando /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: errore durante la creazione del server \"%s\""

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-11-23 09:00+0900\n"
"Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n"
"Language-Team: Japanese <https://github.com/l/weechat/tree/master/"
@ -7721,6 +7721,12 @@ msgstr ""
"サーバで使用するカスタムホスト名/IP アドレス (任意、空の場合はローカルホスト"
"名が使われる)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -7834,12 +7840,6 @@ msgid ""
"command instead)"
msgstr "サーバの通知リスト (これを変更する場合は、/notify コマンドを使うこと)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: サーバ \"%s\" 追加中のエラー"

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:24+0200\n"
"Last-Translator: Krzysztof Korościk <soltys1@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -7885,6 +7885,12 @@ msgstr ""
"własna lokalna nazwa hosta/adres IP dla serwera (opcjonalne, jeśli puste "
"użyta zostanie lokalna nazwa hosta)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -8007,12 +8013,6 @@ msgstr ""
"lista powiadomień dla tego serwera (nie powinieneś zmieniać tej opcji tylko "
"użyć w zamian komendy /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: błąd podczas dodawania serwera \"%s\""

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-27 12:29+0000\n"
"Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n"
"Language-Team: Portuguese <>\n"
@ -7884,6 +7884,12 @@ msgstr ""
"nome local de máquina/IP personalizado para o servidor (opcional, se for "
"vazio é utilizado o nome local da máquina)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -8008,12 +8014,6 @@ msgstr ""
"lista de notificação do servidor (não deve alterar esta opção, mas sim usar "
"o comando /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: erro ao adicionar ao servidor \"%s\""

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:24+0200\n"
"Last-Translator: Eduardo Elias <camponez@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6970,6 +6970,12 @@ msgid ""
"used)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -7066,12 +7072,6 @@ msgstr ""
"lista de notificação para o servidor (você não deve alterar esta opção, mas "
"sim utilizar o comando /notify)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s%s: erro ao criar servidor \"%s\""

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-09-03 08:24+0200\n"
"Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6581,6 +6581,12 @@ msgstr ""
"другой ip/хост для сервера (опционально, если не задано - используется "
"локальный хост)"
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
#, fuzzy
msgid ""
"command(s) to run after connection to server and before auto-join of "
@ -6677,12 +6683,6 @@ msgid ""
"command instead)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%s недостаточно памяти для сообщения в строке информации\n"

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2016-05-18 07:43+0200\n"
"Last-Translator: Hasan Kiran <sunder67@hotmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5897,6 +5897,12 @@ msgid ""
"used)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -5975,12 +5981,6 @@ msgid ""
"command instead)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, fuzzy, c-format
msgid "%s%s: error adding server \"%s\""
msgstr "%sFiltre eklenirken hata"

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2016-12-11 13:38+0100\n"
"POT-Creation-Date: 2016-12-11 13:49+0100\n"
"PO-Revision-Date: 2014-08-16 10:27+0200\n"
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5821,6 +5821,12 @@ msgid ""
"used)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\" (note: content is evaluated, see /help eval)"
msgstr ""
msgid ""
"command(s) to run after connection to server and before auto-join of "
"channels (many commands can be separated by \";\", use \"\\;\" for a "
@ -5899,12 +5905,6 @@ msgid ""
"command instead)"
msgstr ""
msgid ""
"usermode to set after connection to server and before executing command and "
"the auto-join of channels; this option gives same result as defining a "
"command \"/mode $nick <mode>\""
msgstr ""
#, c-format
msgid "%s%s: error adding server \"%s\""
msgstr ""

View File

@ -1981,6 +1981,26 @@ irc_config_server_new_option (struct t_config_file *config_file,
callback_change_data,
NULL, NULL, NULL);
break;
case IRC_SERVER_OPTION_USERMODE:
new_option = weechat_config_new_option (
config_file, section,
option_name, "string",
N_("usermode to set after connection to server and before "
"executing command and the auto-join of channels; this "
"option gives same result as defining a command "
"\"/mode $nick <mode>\" "
"(note: content is evaluated, see /help eval)"),
NULL, 0, 0,
default_value, value,
null_value_allowed,
callback_check_value,
callback_check_value_pointer,
callback_check_value_data,
callback_change,
callback_change_pointer,
callback_change_data,
NULL, NULL, NULL);
break;
case IRC_SERVER_OPTION_COMMAND:
new_option = weechat_config_new_option (
config_file, section,
@ -2244,25 +2264,6 @@ irc_config_server_new_option (struct t_config_file *config_file,
callback_change_data,
NULL, NULL, NULL);
break;
case IRC_SERVER_OPTION_USERMODE:
new_option = weechat_config_new_option (
config_file, section,
option_name, "string",
N_("usermode to set after connection to server and before "
"executing command and the auto-join of channels; this "
"option gives same result as defining a command "
"\"/mode $nick <mode>\""),
NULL, 0, 0,
default_value, value,
null_value_allowed,
callback_check_value,
callback_check_value_pointer,
callback_check_value_data,
callback_change,
callback_change_pointer,
callback_change_data,
NULL, NULL, NULL);
break;
case IRC_SERVER_NUM_OPTIONS:
break;
}

View File

@ -2453,7 +2453,7 @@ IRC_PROTOCOL_CALLBACK(wallops)
IRC_PROTOCOL_CALLBACK(001)
{
char *server_command, **commands, **ptr_command, *vars_replaced, *away_msg;
const char *usermode;
char *usermode;
IRC_PROTOCOL_MIN_ARGS(3);
@ -2494,7 +2494,9 @@ IRC_PROTOCOL_CALLBACK(001)
WEECHAT_HOOK_SIGNAL_STRING, server->name);
/* set usermode when connected */
usermode = IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_USERMODE);
usermode = weechat_string_eval_expression (
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_USERMODE),
NULL, NULL, NULL);
if (usermode && usermode[0])
{
irc_server_sendf (server,
@ -2502,11 +2504,13 @@ IRC_PROTOCOL_CALLBACK(001)
"MODE %s %s",
server->nick, usermode);
}
if (usermode)
free (usermode);
/* execute command when connected */
server_command = weechat_string_eval_expression (IRC_SERVER_OPTION_STRING(server,
IRC_SERVER_OPTION_COMMAND),
NULL, NULL, NULL);
server_command = weechat_string_eval_expression (
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_COMMAND),
NULL, NULL, NULL);
if (server_command && server_command[0])
{
/* split command on ';' which can be escaped with '\;' */
@ -2531,8 +2535,9 @@ IRC_PROTOCOL_CALLBACK(001)
irc_server_autojoin_channels (server);
}
else
{
irc_server_autojoin_channels (server);
}
if (server_command)
free (server_command);