mirror of
https://github.com/weechat/weechat.git
synced 2026-06-25 12:26:40 +02:00
Add IRC options to customize target buffer for messages (task #7381)
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
WeeChat ChangeLog
|
||||
=================
|
||||
FlashCode <flashcode@flashtux.org>
|
||||
v0.3.1-dev, 2009-12-16
|
||||
v0.3.1-dev, 2009-12-31
|
||||
|
||||
|
||||
Version 0.3.1 (under dev!)
|
||||
@@ -24,6 +24,7 @@ Version 0.3.1 (under dev!)
|
||||
* alias: fix bug with buffer for execution of alias, when called from plugin API
|
||||
with function "command" (bug #27697)
|
||||
* alias: fix bug with arguments (bug #27440)
|
||||
* irc: add options to customize target buffer for messages (task #7381)
|
||||
* irc: use self-signed certificate to auto identify on IRC server (CertFP)
|
||||
(task #7492, debian #453348)
|
||||
* irc: check SSL certificates (task #7492)
|
||||
|
||||
@@ -75,6 +75,7 @@ my %plugin_list = ("weechat" => "co", "alias" => "",
|
||||
my @ignore_options = ("aspell\\.dict\\..*",
|
||||
"charset\\.decode\\..*",
|
||||
"charset\\.encode\\..*",
|
||||
"irc\\.msgbuffer\\..*",
|
||||
"irc\\.ctcp\\..*",
|
||||
"irc\\.ignore\\..*",
|
||||
"irc\\.server\\..*",
|
||||
|
||||
@@ -73,6 +73,11 @@
|
||||
** type: integer
|
||||
** values: buffer_plugin, buffer_name (default value: buffer_plugin)
|
||||
|
||||
* *irc.look.msgbuffer_fallback*
|
||||
** description: default target buffer for msgbuffer options when target is private and that private buffer is not found
|
||||
** type: integer
|
||||
** values: current, server (default value: current)
|
||||
|
||||
* *irc.look.nick_completion_smart*
|
||||
** description: smart completion for nicks (completes first with last speakers)
|
||||
** type: integer
|
||||
|
||||
@@ -4403,14 +4403,14 @@ Arguments:
|
||||
|
||||
* 'prefix': name of prefix:
|
||||
|
||||
[width="70%",cols="^2,^1,^3,5",options="header"]
|
||||
[width="70%",cols="^2e,^1l,^3,5",options="header"]
|
||||
|========================================
|
||||
| Prefix | Value | Color | Description
|
||||
| 'error' | `=!=` | yellow | error message
|
||||
| 'network' | `--` | magenta | message from network
|
||||
| 'action' | `*` | white | self action
|
||||
| 'join' | `-->` | lightgreen | someone joins current chat
|
||||
| 'quit' | `<--` | lightred | someone leaves current chat
|
||||
| Prefix | Value | Color | Description
|
||||
| error | =!= | yellow | error message
|
||||
| network | -- | magenta | message from network
|
||||
| action | * | white | self action
|
||||
| join | --> | lightgreen | someone joins current chat
|
||||
| quit | <-- | lightred | someone leaves current chat
|
||||
|========================================
|
||||
|
||||
[NOTE]
|
||||
|
||||
+137
-38
@@ -235,65 +235,65 @@ Screen is composed by following areas:
|
||||
|
||||
Bar 'status' has following default items:
|
||||
|
||||
[width="100%",cols="^3,^3,10",options="header"]
|
||||
[width="100%",cols="^3,^3l,10",options="header"]
|
||||
|========================================
|
||||
| Item | Example | Description
|
||||
| Item | Example | Description
|
||||
|
||||
| time | `[12:55]` |
|
||||
| time | [12:55] |
|
||||
time
|
||||
|
||||
| buffer_count | `[4]` |
|
||||
| buffer_count | [4] |
|
||||
number of opened buffers
|
||||
|
||||
| buffer_plugin | `[irc]` |
|
||||
| buffer_plugin | [irc/freenode] |
|
||||
plugin of current buffer (irc plugin can add IRC server name used by buffer)
|
||||
|
||||
| buffer_number | `3` |
|
||||
| buffer_number | 3 |
|
||||
current buffer number
|
||||
|
||||
| buffer_name | `freenode/#test(+n)` |
|
||||
| buffer_name | #test(+n) |
|
||||
current buffer name
|
||||
|
||||
| buffer_nicklist_count | `{5}` |
|
||||
| buffer_nicklist_count | {5} |
|
||||
number of nicks in nicklist
|
||||
|
||||
| buffer_filter | `*` |
|
||||
| buffer_filter | * |
|
||||
filtering indicator: `*` means some lines are filtered (hidden), empty value
|
||||
means all lines are displayed
|
||||
|
||||
| lag | `[Lag: 2.5]` |
|
||||
| lag | [Lag: 2.5] |
|
||||
lag indicator, in seconds (hidden if lag is low)
|
||||
|
||||
| hotlist | `[Act: 4,2]` |
|
||||
| hotlist | [Act: 4,2] |
|
||||
list of buffers with activity (unread messages)
|
||||
|
||||
| completion | `abc(2) def(5)` |
|
||||
| completion | abc(2) def(5) |
|
||||
list of words for completion, with number of possible completions for each
|
||||
word
|
||||
|
||||
| scroll | `-MORE(50)-` |
|
||||
| scroll | -MORE(50)- |
|
||||
scroll indicator, with number of lines below last line displayed
|
||||
|========================================
|
||||
|
||||
Bar 'input' has following default items:
|
||||
|
||||
[width="100%",cols="^3,^6,8",options="header"]
|
||||
[width="100%",cols="^3,^6m,8",options="header"]
|
||||
|========================================
|
||||
| Item | Example | Description
|
||||
|
||||
| input_paste | `[Paste 7 lines ? [ctrl-Y] Yes [ctrl-N] No]` |
|
||||
| input_paste | [Paste 7 lines ? [ctrl-Y] Yes [ctrl-N] No] |
|
||||
question to user for pasting lines
|
||||
|
||||
| input_prompt | `[nick]` |
|
||||
| input_prompt | [nick] |
|
||||
input prompt (nick for irc plugin)
|
||||
|
||||
| away | `(away)` |
|
||||
| away | (away) |
|
||||
away indicator
|
||||
|
||||
| input_search | `[Text search]` |
|
||||
| input_search | [Text search] |
|
||||
text search indicator
|
||||
|
||||
| input_text | `bla bla...` |
|
||||
| input_text | bla bla... |
|
||||
input text
|
||||
|========================================
|
||||
|
||||
@@ -1054,33 +1054,132 @@ If you want to restore standard CTCP reply, then remove option:
|
||||
Following codes can be used in strings and are automatically expanded by WeeChat
|
||||
when replying to CTCP:
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2l,4,8l",options="header"]
|
||||
|========================================
|
||||
| Code | Description | Value/example
|
||||
| `$clientinfo` | list of supported CTCP | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| `$version` | WeeChat version | `0.3.0`
|
||||
| `$compilation` | WeeChat compilation date | `Sep 13 2009`
|
||||
| `$osinfo` | info about OS | `Linux 2.6.31 / i686`
|
||||
| `$site` | WeeChat site | `http://www.weechat.org`
|
||||
| `$download` | WeeChat site, download page | `http://www.weechat.org/download`
|
||||
| `$time` | current date/time | `Sun Sep 13 15:48:31 2009`
|
||||
| `$username` | username on IRC server | `nick`
|
||||
| `$realname` | realname on IRC server | `My name`
|
||||
| Code | Description | Value/example
|
||||
| $clientinfo | list of supported CTCP | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| $version | WeeChat version | 0.3.0
|
||||
| $compilation | WeeChat compilation date | Sep 13 2009
|
||||
| $osinfo | info about OS | Linux 2.6.31 / i686
|
||||
| $site | WeeChat site | http://www.weechat.org
|
||||
| $download | WeeChat site, download page | http://www.weechat.org/download
|
||||
| $time | current date/time | Sun Sep 13 15:48:31 2009
|
||||
| $username | username on IRC server | nick
|
||||
| $realname | realname on IRC server | My name
|
||||
|========================================
|
||||
|
||||
If CTCP options are not defined (by default), CTCP replies are:
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2,4l,8l",options="header"]
|
||||
|========================================
|
||||
| CTCP | Reply format | Example
|
||||
| CLIENTINFO | `$clientinfo` | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| FINGER | `WeeChat $version` | `WeeChat 0.3.0`
|
||||
| SOURCE | `$download` | `http://www.weechat.org/download`
|
||||
| TIME | `$time` | `Sun Sep 13 15:48:31 2009`
|
||||
| USERINFO | `$username ($realname)` | `nick (My name)`
|
||||
| VERSION | `WeeChat $version ($compilation)` | `WeeChat 0.3.0 (Sep 13 2009)`
|
||||
| CTCP | Reply format | Example
|
||||
| CLIENTINFO | $clientinfo | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| FINGER | WeeChat $version | WeeChat 0.3.0
|
||||
| SOURCE | $download | http://www.weechat.org/download
|
||||
| TIME | $time | Sun Sep 13 15:48:31 2009
|
||||
| USERINFO | $username ($realname) | nick (My name)
|
||||
| VERSION | WeeChat $version ($compilation) | WeeChat 0.3.0 (Sep 13 2009)
|
||||
|========================================
|
||||
|
||||
[[target_buffer]]
|
||||
Target buffer for IRC messages
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
It is possible to customize target buffer for IRC messages (buffer used to
|
||||
display message) with options `irc.msgbuffer.*`.
|
||||
|
||||
For some IRC messages (see list below), you can use value:
|
||||
|
||||
current::
|
||||
current buffer (if it's IRC buffer, or on server buffer by default)
|
||||
|
||||
private::
|
||||
private buffer for nick, or current/server buffer if not found (according
|
||||
to option 'irc.look.msgbuffer_fallback')
|
||||
|
||||
weechat::
|
||||
WeeChat "core" buffer
|
||||
|
||||
Default is server buffer (when option is not set).
|
||||
|
||||
Non-exhaustive list of IRC messages or alias that you can customize:
|
||||
|
||||
[width="50%",cols="^1m,^1m,3",options="header"]
|
||||
|========================================
|
||||
| message | alias | description
|
||||
| invite | | invited on a channel
|
||||
| notice | | notice
|
||||
| wallops | | wallops
|
||||
| 221 | | user mode string
|
||||
| 275 | whois | whois (secure connection)
|
||||
| 303 | | ison
|
||||
| 305 | unaway | unaway
|
||||
| 306 | away | away
|
||||
| 307 | whois | whois (registered nick)
|
||||
| 310 | whois | whois (help mode)
|
||||
| 311 | whois | whois (user)
|
||||
| 312 | whois | whois (server)
|
||||
| 313 | whois | whois (operator)
|
||||
| 314 | whowas | whowas
|
||||
| 315 | who | who (end)
|
||||
| 317 | whois | whois (idle)
|
||||
| 318 | whois | whois (end)
|
||||
| 319 | whois | whois (channels)
|
||||
| 320 | whois | whois (identified user)
|
||||
| 321 | list | list (start)
|
||||
| 322 | list | list (channel)
|
||||
| 323 | list | list (end)
|
||||
| 326 | whois | whois (has oper privs)
|
||||
| 327 | whois | whois (host)
|
||||
| 330 | whois | whois (logged in as)
|
||||
| 335 | whois | whois (is a bot on)
|
||||
| 338 | whois | whois (host)
|
||||
| 341 | | inviting
|
||||
| 344 | reop | channel reop
|
||||
| 345 | reop | channel reop (end)
|
||||
| 351 | | server version
|
||||
| 352 | who | who
|
||||
| 369 | whowas | whowas (end)
|
||||
| 378 | whois | whois (connecting from)
|
||||
| 379 | whois | whois (using modes)
|
||||
| 432 | | erroneous nickname
|
||||
| 433 | | nickname already in use
|
||||
| 438 | | not authorized to change nickname
|
||||
| 671 | whois | whois (secure connection)
|
||||
| 901 | | you are now logged in
|
||||
|========================================
|
||||
|
||||
Other numeric commands can be customized as well.
|
||||
|
||||
Message can be prefixed by server name to be specific to an irc server
|
||||
(for example: `freenode.whois`).
|
||||
|
||||
Some examples:
|
||||
|
||||
* display result of `/whois` on private buffer:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.whois private
|
||||
----------------------------------------
|
||||
|
||||
* restore default buffer for whois (server buffer):
|
||||
|
||||
----------------------------------------
|
||||
/unset irc.msgbuffer.whois
|
||||
----------------------------------------
|
||||
|
||||
* display invitation on current buffer, only for "freenode" server:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.freenode.invite current
|
||||
----------------------------------------
|
||||
|
||||
* display message "303" (ison) on WeeChat "core" buffer:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.303 weechat
|
||||
----------------------------------------
|
||||
|
||||
[[logger_plugin]]
|
||||
Logger plugin
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
@@ -73,6 +73,11 @@
|
||||
** type: entier
|
||||
** valeurs: buffer_plugin, buffer_name (valeur par défaut: buffer_plugin)
|
||||
|
||||
* *irc.look.msgbuffer_fallback*
|
||||
** description: tampon cible par défaut pour les options msgbuffer quand la cible est "private" et que le tampon privé n'est pas trouvé
|
||||
** type: entier
|
||||
** valeurs: current, server (valeur par défaut: current)
|
||||
|
||||
* *irc.look.nick_completion_smart*
|
||||
** description: complétion intelligente pour les pseudos (complète d'abord avec les personnes qui ont parlé récemment)
|
||||
** type: entier
|
||||
|
||||
@@ -4452,14 +4452,14 @@ Paramètres :
|
||||
|
||||
* 'prefix' : nom du préfixe :
|
||||
|
||||
[width="70%",cols="^2,^1,^3,5",options="header"]
|
||||
[width="70%",cols="^2e,^1l,^3,5",options="header"]
|
||||
|========================================
|
||||
| Préfixe | Valeur | Couleur | Description
|
||||
| 'error' | `=!=` | jaune ("yellow") | message d'erreur
|
||||
| 'network' | `--` | violet ("magenta") | message du réseau
|
||||
| 'action' | `*` | blanc ("white") | action personnelle
|
||||
| 'join' | `-->` | vert clair ("lightgreen") | quelqu'un a rejoint la discussion
|
||||
| 'quit' | `<--` | rouge clair ("lightred") | quelqu'un a quitté la discussion
|
||||
| Préfixe | Valeur | Couleur | Description
|
||||
| error | =!= | jaune ("yellow") | message d'erreur
|
||||
| network | -- | violet ("magenta") | message du réseau
|
||||
| action | * | blanc ("white") | action personnelle
|
||||
| join | --> | vert clair ("lightgreen") | quelqu'un a rejoint la discussion
|
||||
| quit | <-- | rouge clair ("lightred") | quelqu'un a quitté la discussion
|
||||
|========================================
|
||||
|
||||
[NOTE]
|
||||
|
||||
+139
-38
@@ -240,68 +240,68 @@ L'écran est composé des zones suivantes :
|
||||
|
||||
La barre 'status' contient les objets (items) suivants par défaut :
|
||||
|
||||
[width="100%",cols="^3,^3,10",options="header"]
|
||||
[width="100%",cols="^3,^3l,10",options="header"]
|
||||
|========================================
|
||||
| Objet (item) | Exemple | Description
|
||||
| Objet (item) | Exemple | Description
|
||||
|
||||
| time | `[12:55]` |
|
||||
| time | [12:55] |
|
||||
heure
|
||||
|
||||
| buffer_count | `[4]` |
|
||||
| buffer_count | [4] |
|
||||
nombre de tampons ouverts
|
||||
|
||||
| buffer_plugin | `[irc/freenode]` |
|
||||
| buffer_plugin | [irc/freenode] |
|
||||
extension du tampon courant (l'extension irc peut afficher le nom du serveur
|
||||
IRC auquel est rattaché ce tampon)
|
||||
|
||||
| buffer_number | `3` |
|
||||
| buffer_number | 3 |
|
||||
numéro du tampon courant
|
||||
|
||||
| buffer_name | `freenode/#test(+n)` |
|
||||
| buffer_name | #test(+n) |
|
||||
nom du tampon courant
|
||||
|
||||
| buffer_nicklist_count | `{5}` |
|
||||
| buffer_nicklist_count | {5} |
|
||||
nombre de pseudos dans la liste des pseudos
|
||||
|
||||
| buffer_filter | `*` |
|
||||
| buffer_filter | * |
|
||||
indicateur de filtrage : `*` signifie que des lignes sont filtrées (cachées),
|
||||
une valeur vide signifie que toutes les lignes sont affichées
|
||||
|
||||
| lag | `[Lag: 2.5]` |
|
||||
| lag | [Lag: 2.5] |
|
||||
indicateur de "lag" (ralentissements réseau), en secondes (caché si le lag
|
||||
est faible)
|
||||
|
||||
| hotlist | `[Act: 4,2]` |
|
||||
| hotlist | [Act: 4,2] |
|
||||
liste des tampons où il y a de l'activité (messages non lus)
|
||||
|
||||
| completion | `abc(2) def(5)` |
|
||||
| completion | abc(2) def(5) |
|
||||
liste des mots pour la complétion, avec le nombre de complétions possibles
|
||||
pour chaque mot
|
||||
|
||||
| scroll | `-PLUS(50)-` |
|
||||
| scroll | -PLUS(50)- |
|
||||
indicateur de scroll, avec le nombre de lignes sous la dernière ligne
|
||||
affichée
|
||||
|========================================
|
||||
|
||||
La barre 'input' contient les objets (items) suivants par défaut :
|
||||
|
||||
[width="100%",cols="^3,^6,8",options="header"]
|
||||
[width="100%",cols="^3,^6l,8",options="header"]
|
||||
|========================================
|
||||
| Objet (item) | Exemple | Description
|
||||
|
||||
| input_paste | `[Coller 7 lignes ? [ctrl-Y] Oui [ctrl-N] Non]` |
|
||||
| input_paste | [Coller 7 lignes ? [ctrl-Y] Oui [ctrl-N] Non] |
|
||||
question à l'utilisateur pour coller des lignes
|
||||
|
||||
| input_prompt | `[pseudo]` |
|
||||
| input_prompt | [pseudo] |
|
||||
prompt (pseudo pour l'extension irc)
|
||||
|
||||
| away | `(absent)` |
|
||||
| away | (absent) |
|
||||
indicateur d'absence
|
||||
|
||||
| input_search | `[Recherche texte]` |
|
||||
| input_search | [Recherche texte] |
|
||||
indicateur de recherche de texte
|
||||
|
||||
| input_text | `bla bla...` |
|
||||
| input_text | bla bla... |
|
||||
texte entré
|
||||
|========================================
|
||||
|
||||
@@ -1090,33 +1090,134 @@ Si vous voulez restaurer la réponse CTCP standard, alors supprimez l'option :
|
||||
Les codes suivants peuvent être utilisés dans les chaînes et sont
|
||||
automatiquement remplacées par WeeChat lors de la réponse au CTCP :
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2l,4,8l",options="header"]
|
||||
|========================================
|
||||
| Code | Description | Valeur / exemple
|
||||
| `$clientinfo` | liste des CTCP supportés | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| `$version` | version de WeeChat | `0.3.0`
|
||||
| `$compilation` | date de compi lation WeeChat | `Sep 13 2009`
|
||||
| `$osinfo` | information sur l'OS | `Linux 2.6.31 / i686`
|
||||
| `$site` | site WeeChat | `http://www.weechat.org`
|
||||
| `$download` | site WeeChat, page téléchargement | `http://www.weechat.org/download`
|
||||
| `$time` | date/heure courante | `Sun Sep 13 15:48:31 2009`
|
||||
| `$username` | nom d'utilisateur sur le serveur | `pseudo`
|
||||
| `$realname` | nom réel sur le serveur | `Mon nom`
|
||||
| Code | Description | Valeur / exemple
|
||||
| $clientinfo | liste des CTCP supportés | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| $version | version de WeeChat | 0.3.0
|
||||
| $compilation | date de compi lation WeeChat | Sep 13 2009
|
||||
| $osinfo | information sur l'OS | Linux 2.6.31 / i686
|
||||
| $site | site WeeChat | http://www.weechat.org
|
||||
| $download | site WeeChat, page téléchargement | http://www.weechat.org/download
|
||||
| $time | date/heure courante | Sun Sep 13 15:48:31 2009
|
||||
| $username | nom d'utilisateur sur le serveur | pseudo
|
||||
| $realname | nom réel sur le serveur | Mon nom
|
||||
|========================================
|
||||
|
||||
Si les options CTCP ne sont pas définies (par défaut), les réponses CTCP sont :
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2,4l,8l",options="header"]
|
||||
|========================================
|
||||
| CTCP | Format de réponse | Exemple
|
||||
| CLIENTINFO | `$clientinfo` | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| FINGER | `WeeChat $version` | `WeeChat 0.3.0`
|
||||
| SOURCE | `$download` | `http://www.weechat.org/download`
|
||||
| TIME | `$time` | `Sun Sep 13 15:48:31 2009`
|
||||
| USERINFO | `$username ($realname)` | `pseudo (Mon nom)`
|
||||
| VERSION | `WeeChat $version ($compilation)` | `WeeChat 0.3.0 (Sep 13 2009)`
|
||||
| CTCP | Format de réponse | Exemple
|
||||
| CLIENTINFO | $clientinfo | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| FINGER | WeeChat $version | WeeChat 0.3.0
|
||||
| SOURCE | $download | http://www.weechat.org/download
|
||||
| TIME | $time | Sun Sep 13 15:48:31 2009
|
||||
| USERINFO | $username ($realname) | pseudo (Mon nom)
|
||||
| VERSION | WeeChat $version ($compilation) | WeeChat 0.3.0 (Sep 13 2009)
|
||||
|========================================
|
||||
|
||||
[[target_buffer]]
|
||||
Tampon cible pour les messages IRC
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
Il est possible de personnaliser le tampon cible pour les messages IRC (le
|
||||
tampon utilisé pour afficher le message) avec les options `irc.msgbuffer.*`.
|
||||
|
||||
Pour certains messages IRC (voir la liste ci-dessous), vous pouvez utiliser
|
||||
la valeur :
|
||||
|
||||
current::
|
||||
tampon courant (si c'est un tampon IRC, sinon sur le tampon du serveur)
|
||||
|
||||
private::
|
||||
tampon privé pour le pseudo, ou le tampon courant s'il n'est pas trouvé
|
||||
(selon l'option 'irc.look.msgbuffer_fallback')
|
||||
|
||||
weechat::
|
||||
tampon "core" WeeChat
|
||||
|
||||
Par défaut, le tampon du serveur est utilisé (quand l'option n'est pas définie).
|
||||
|
||||
Liste non exhaustive des messages ou alias que vous pouvez paramétrer :
|
||||
|
||||
[width="50%",cols="^1m,^1m,3",options="header"]
|
||||
|========================================
|
||||
| message | alias | description
|
||||
| invite | | invité sur un canal
|
||||
| notice | | notice
|
||||
| wallops | | wallops
|
||||
| 221 | | chaîne de mode utilisateur
|
||||
| 275 | whois | whois (connexion sécurisée)
|
||||
| 303 | | ison
|
||||
| 305 | unaway | non absent
|
||||
| 306 | away | absent
|
||||
| 307 | whois | whois (pseudo enregistré)
|
||||
| 310 | whois | whois (mode aide)
|
||||
| 311 | whois | whois (utilisateur)
|
||||
| 312 | whois | whois (serveur)
|
||||
| 313 | whois | whois (opérateur)
|
||||
| 314 | whowas | whowas
|
||||
| 315 | who | who (fin)
|
||||
| 317 | whois | whois (inactivité)
|
||||
| 318 | whois | whois (fin)
|
||||
| 319 | whois | whois (canaux)
|
||||
| 320 | whois | whois (utilisateur identifié)
|
||||
| 321 | list | list (début)
|
||||
| 322 | list | list (canal)
|
||||
| 323 | list | list (fin)
|
||||
| 326 | whois | whois (a les privilèges oper)
|
||||
| 327 | whois | whois (machine)
|
||||
| 330 | whois | whois (identifié comme)
|
||||
| 335 | whois | whois (est un robot sur)
|
||||
| 338 | whois | whois (machine)
|
||||
| 341 | | invitation
|
||||
| 344 | reop | reop canal
|
||||
| 345 | reop | reop canal (fin)
|
||||
| 351 | | version du serveur
|
||||
| 352 | who | who
|
||||
| 369 | whowas | whowas (fin)
|
||||
| 378 | whois | whois (connection depuis)
|
||||
| 379 | whois | whois (utilise les modes)
|
||||
| 432 | | pseudo erroné
|
||||
| 433 | | pseudo déjà en cours d'utilisation
|
||||
| 438 | | pas autorisé à changer de pseudo
|
||||
| 671 | whois | whois (connexion sécurisée)
|
||||
| 901 | | vous êtes maintenant identifié
|
||||
|========================================
|
||||
|
||||
Les autres messages numériques peuvent être paramétrés de la même manière.
|
||||
|
||||
Le message peut être préfixé par le nom du serveur pour être spécifique à un
|
||||
serveur IRC (par exemple: `freenode.whois`).
|
||||
|
||||
Quelques exemples:
|
||||
|
||||
* afficher le résultat de `/whois` sur le tampon privé:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.whois private
|
||||
----------------------------------------
|
||||
|
||||
* restaurer le tampon par défaut pour whois (tampon du serveur):
|
||||
|
||||
----------------------------------------
|
||||
/unset irc.msgbuffer.whois
|
||||
----------------------------------------
|
||||
|
||||
* afficher une invitation sur le tampon courant, pour le serveur "freenode"
|
||||
seulement :
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.freenode.invite current
|
||||
----------------------------------------
|
||||
|
||||
* afficher le message "303" (ison) sur le tampon "core" WeeChat:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.303 weechat
|
||||
----------------------------------------
|
||||
|
||||
[[logger_plugin]]
|
||||
Extension Logger
|
||||
~~~~~~~~~~~~~~~~
|
||||
|
||||
@@ -73,6 +73,11 @@
|
||||
** tipo: intero
|
||||
** valori: buffer_plugin, buffer_name (valore predefinito: buffer_plugin)
|
||||
|
||||
* *irc.look.msgbuffer_fallback*
|
||||
** descrizione: default target buffer for msgbuffer options when target is private and that private buffer is not found
|
||||
** tipo: intero
|
||||
** valori: current, server (valore predefinito: current)
|
||||
|
||||
* *irc.look.nick_completion_smart*
|
||||
** descrizione: completamento intelligente per i nick (usando prima chi ha parlato per ultimo)
|
||||
** tipo: intero
|
||||
|
||||
+137
-38
@@ -240,67 +240,67 @@ Lo schermo è composto dalle seguenti aree:
|
||||
|
||||
La barra 'stato' ha i seguenti elementi predefiniti:
|
||||
|
||||
[width="100%",cols="^3,^3,10",options="header"]
|
||||
[width="100%",cols="^3,^3l,10",options="header"]
|
||||
|=======================================
|
||||
| Elemento | Esempio | Descrizione
|
||||
| Elemento | Esempio | Descrizione
|
||||
|
||||
| time | `[12:55]` |
|
||||
| time | [12:55] |
|
||||
ora
|
||||
|
||||
| buffer_count | `[4]` |
|
||||
| buffer_count | [4] |
|
||||
numero di buffer aperti
|
||||
|
||||
| buffer_plugin | `[irc]` |
|
||||
| buffer_plugin | [irc/freenode] |
|
||||
plugin del buffer attivo (il plugin irc può aggiungere il nome del server irc
|
||||
usato dal buffer)
|
||||
|
||||
| buffer_number | `3` |
|
||||
| buffer_number | 3 |
|
||||
numero del buffer corrente
|
||||
|
||||
| buffer_name | `freenode/#test(+n)` |
|
||||
| buffer_name | #test(+n) |
|
||||
nome del buffer attivo
|
||||
|
||||
| buffer_nicklist_count | `{5}` |
|
||||
| buffer_nicklist_count | {5} |
|
||||
numero di nick nella lista nick
|
||||
|
||||
| buffer_filter | `*` |
|
||||
| buffer_filter | * |
|
||||
indicatore filtraggio: `*` significa che alcune righe sono filtrate (nascoste),
|
||||
valori vuoti indicano che tutte le righe sono visualizzate
|
||||
|
||||
| lag | `[Ritardo: 2.5]` |
|
||||
| lag | [Ritardo: 2.5] |
|
||||
indicatore ritardo, in secondi (nascosto se il ritardo è basso)
|
||||
|
||||
| hotlist | `[Attività: 4,2]` |
|
||||
| hotlist | [Attività: 4,2] |
|
||||
elenco dei buffer con attività (messaggi non letti)
|
||||
|
||||
| completion | `abc(2) def(5)` |
|
||||
| completion | abc(2) def(5) |
|
||||
elenco di parole per il completamento, con il numero di completamenti
|
||||
possibili per ogni parola
|
||||
|
||||
| scroll | `-ANCORA(50)-` |
|
||||
| scroll | -ANCORA(50)- |
|
||||
indicatore di scorrimento, con il numero di righe sotto l'ultima
|
||||
riga visualizzata
|
||||
|=======================================
|
||||
|
||||
La barra 'input' ha i seguenti elementi predefiniti:
|
||||
|
||||
[width="100%",cols="^3,^6,8",options="header"]
|
||||
[width="100%",cols="^3,^6l,8",options="header"]
|
||||
|=======================================
|
||||
| Elemento | Esempio | Descrizione
|
||||
|
||||
| input_paste | `[Incollare 7 righe ? [ctrl-Y] Sì [ctrl-N] No]` |
|
||||
| input_paste | [Incollare 7 righe ? [ctrl-Y] Sì [ctrl-N] No] |
|
||||
chiede all'utente se incollare le righe
|
||||
|
||||
| input_prompt | `[nick]` |
|
||||
| input_prompt | [nick] |
|
||||
prompt per l'input (nick per il plugin irc)
|
||||
|
||||
| away | `(assente)` |
|
||||
| away | (assente) |
|
||||
indicatore di assenza
|
||||
|
||||
| input_search | `[Ricerca testo]` |
|
||||
| input_search | [Ricerca testo] |
|
||||
indicatore di ricerca testo
|
||||
|
||||
| input_text | `bla bla...` |
|
||||
| input_text | bla bla... |
|
||||
testo in input
|
||||
|=======================================
|
||||
|
||||
@@ -1078,34 +1078,133 @@ l'opzione:
|
||||
I codici seguenti possono essere utilizzati nelle stringhe e vengono estese
|
||||
automaticamente da WeeChat quando si risponde alle CTCP
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2l,4,8l",options="header"]
|
||||
|=======================================
|
||||
| Codice | Descrizione | Valore/esempio
|
||||
| `$clientinfo` | elenco di CTCP supportate | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| `$version` | versione di WeeChat | `0.3.0`
|
||||
| `$compilation` | data di compilazione di WeeChat | `Sep 13 2009`
|
||||
| `$osinfo` | informazioni sull'OS | `Linux 2.6.31 / i686`
|
||||
| `$site` | sito di WeeChat | `http://www.weechat.org`
|
||||
| `$download` | sito di WeeChat, pagina di download | `http://www.weechat.org/download`
|
||||
| `$time` | data/ora correnti | `Sun Sep 13 15:48:31 2009`
|
||||
| `$username` | nome utente sul server IRC | `nick`
|
||||
| `$realname` | nome reale sul server IRC | `Mio nome`
|
||||
| Codice | Descrizione | Valore/esempio
|
||||
| $clientinfo | elenco di CTCP supportate | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| $version | versione di WeeChat | 0.3.0
|
||||
| $compilation | data di compilazione di WeeChat | Sep 13 2009
|
||||
| $osinfo | informazioni sull'OS | Linux 2.6.31 / i686
|
||||
| $site | sito di WeeChat | http://www.weechat.org
|
||||
| $download | sito di WeeChat, pagina di download | http://www.weechat.org/download
|
||||
| $time | data/ora correnti | Sun Sep 13 15:48:31 2009
|
||||
| $username | nome utente sul server IRC | nick
|
||||
| $realname | nome reale sul server IRC | Mio nome
|
||||
|=======================================
|
||||
|
||||
Se le opzioni CTCP non sono definite (comportamento predefinito),
|
||||
le risposte CTCP sono:
|
||||
|
||||
[width="100%",cols="^2,4,8",options="header"]
|
||||
[width="100%",cols="^2,4l,8l",options="header"]
|
||||
|=======================================
|
||||
| CTCP | Formato risposta | Esempio
|
||||
| CLIENTINFO | `$clientinfo` | `ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION`
|
||||
| FINGER | `WeeChat $version` | `WeeChat 0.3.0`
|
||||
| SOURCE | `$download` | `http://www.weechat.org/download`
|
||||
| TIME | `$time` | `Sun Sep 13 15:48:31 2009`
|
||||
| USERINFO | `$username ($realname)` | `nick (Mio nome)`
|
||||
| VERSION | `WeeChat $version ($compilation)` | `WeeChat 0.3.0 (Sep 13 2009)`
|
||||
| CTCP | Formato risposta | Esempio
|
||||
| CLIENTINFO | $clientinfo | ACTION DCC CLIENTINFO FINGER PING SOURCE TIME USERINFO VERSION
|
||||
| FINGER | WeeChat $version | WeeChat 0.3.0
|
||||
| SOURCE | $download | http://www.weechat.org/download
|
||||
| TIME | $time | Sun Sep 13 15:48:31 2009
|
||||
| USERINFO | $username ($realname) | nick (Mio nome)
|
||||
| VERSION | WeeChat $version ($compilation) | WeeChat 0.3.0 (Sep 13 2009)
|
||||
|=======================================
|
||||
|
||||
[[target_buffer]]
|
||||
Target buffer for IRC messages
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
It is possible to customize target buffer for IRC messages (buffer used to
|
||||
display message) with options `irc.msgbuffer.*`.
|
||||
|
||||
For some IRC messages (see list below), you can use value:
|
||||
|
||||
current::
|
||||
current buffer (if it's IRC buffer, or on server buffer by default)
|
||||
|
||||
private::
|
||||
private buffer for nick, or current buffer if not found (according
|
||||
to option 'irc.look.msgbuffer_fallback')
|
||||
|
||||
weechat::
|
||||
WeeChat "core" buffer
|
||||
|
||||
Default is server buffer (when option is not set).
|
||||
|
||||
Non-exhaustive list of IRC messages or alias that you can customize:
|
||||
|
||||
[width="50%",cols="^1m,^1m,3",options="header"]
|
||||
|========================================
|
||||
| message | alias | description
|
||||
| invite | | invited on a channel
|
||||
| notice | | notice
|
||||
| wallops | | wallops
|
||||
| 221 | | user mode string
|
||||
| 275 | whois | whois (secure connection)
|
||||
| 303 | | ison
|
||||
| 305 | unaway | unaway
|
||||
| 306 | away | away
|
||||
| 307 | whois | whois (registered nick)
|
||||
| 310 | whois | whois (help mode)
|
||||
| 311 | whois | whois (user)
|
||||
| 312 | whois | whois (server)
|
||||
| 313 | whois | whois (operator)
|
||||
| 314 | whowas | whowas
|
||||
| 315 | who | who (end)
|
||||
| 317 | whois | whois (idle)
|
||||
| 318 | whois | whois (end)
|
||||
| 319 | whois | whois (channels)
|
||||
| 320 | whois | whois (identified user)
|
||||
| 321 | list | list (start)
|
||||
| 322 | list | list (channel)
|
||||
| 323 | list | list (end)
|
||||
| 326 | whois | whois (has oper privs)
|
||||
| 327 | whois | whois (host)
|
||||
| 330 | whois | whois (logged in as)
|
||||
| 335 | whois | whois (is a bot on)
|
||||
| 338 | whois | whois (host)
|
||||
| 341 | | inviting
|
||||
| 344 | reop | channel reop
|
||||
| 345 | reop | channel reop (end)
|
||||
| 351 | | server version
|
||||
| 352 | who | who
|
||||
| 369 | whowas | whowas (end)
|
||||
| 378 | whois | whois (connecting from)
|
||||
| 379 | whois | whois (using modes)
|
||||
| 432 | | erroneous nickname
|
||||
| 433 | | nickname already in use
|
||||
| 438 | | not authorized to change nickname
|
||||
| 671 | whois | whois (secure connection)
|
||||
| 901 | | you are now logged in
|
||||
|========================================
|
||||
|
||||
Other numeric commands can be customized as well.
|
||||
|
||||
Message can be prefixed by server name to be specific to an irc server
|
||||
(for example: `freenode.whois`).
|
||||
|
||||
Some examples:
|
||||
|
||||
* display result of `/whois` on private buffer:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.whois private
|
||||
----------------------------------------
|
||||
|
||||
* restore default buffer for whois (server buffer):
|
||||
|
||||
----------------------------------------
|
||||
/unset irc.msgbuffer.whois
|
||||
----------------------------------------
|
||||
|
||||
* display invitation on current buffer, only for "freenode" server:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.freenode.invite current
|
||||
----------------------------------------
|
||||
|
||||
* display message "303" (ison) on WeeChat "core" buffer:
|
||||
|
||||
----------------------------------------
|
||||
/set irc.msgbuffer.303 weechat
|
||||
----------------------------------------
|
||||
|
||||
[[logger_plugin]]
|
||||
Plugin Logger
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
@@ -131,6 +131,8 @@
|
||||
./src/plugins/irc/irc-input.h
|
||||
./src/plugins/irc/irc-mode.c
|
||||
./src/plugins/irc/irc-mode.h
|
||||
./src/plugins/irc/irc-msgbuffer.c
|
||||
./src/plugins/irc/irc-msgbuffer.h
|
||||
./src/plugins/irc/irc-nick.c
|
||||
./src/plugins/irc/irc-nick.h
|
||||
./src/plugins/irc/irc-protocol.c
|
||||
|
||||
@@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-09-14 10:56+0200\n"
|
||||
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3900,6 +3900,13 @@ msgstr ""
|
||||
"%s%s: varování: server \"%s\" nenalezen v konfiguračním souboru, nesmazáno z "
|
||||
"paměti, protože se stále používá"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: chyba vytváření CTCP \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4060,6 +4067,11 @@ msgstr ""
|
||||
msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr "jméno položky pole, kde je IRC server zobrazen (pro stavový řádek)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5868,6 +5880,10 @@ msgstr "%s%s: nemohu nastavit \"neblokovaci\" volbu na soket"
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s%s: vypršel časový limit \"%s\" pro %s"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr "%s%s: chyba vytváření znakové sady \"%s\" => \"%s\""
|
||||
|
||||
#~ msgid "%s%s: error: \"%s\""
|
||||
#~ msgstr "%s%s: chyba: \"%s\""
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-12-20 18:42+0100\n"
|
||||
"Last-Translator: Nils G <weechatter@arcor.de>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -4038,6 +4038,13 @@ msgstr ""
|
||||
"gefunden werden. Da der Server zur Zeit genutzt wird, konnte er noch nicht "
|
||||
"entfernt werden"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: Fehler bei CTCP Erstellung \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4209,6 +4216,11 @@ msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr ""
|
||||
"Name der Bar-Item in dem der IRC Server angezeigt wird (für Status-Bar)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -6065,3 +6077,7 @@ msgstr ""
|
||||
#, c-format
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s%s: Zeitüberschreitung für \"%s\" mit %s"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr "%s%s: Fehler bei Zeichensatz Erstellung \"%s\" => \"%s\""
|
||||
|
||||
@@ -8,7 +8,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-09-06 21:25+0200\n"
|
||||
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3824,6 +3824,13 @@ msgstr ""
|
||||
"%s%s: atención: servidor \"%s\" no encontrado en el archivo de "
|
||||
"configuración, no es borrado de la memoria porque aún está en uso"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: error al crear CTCP \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -3981,6 +3988,11 @@ msgstr ""
|
||||
"nombre del elemento de barra donde el servidor IRC es mostrado (para la "
|
||||
"barra de estado)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5764,6 +5776,10 @@ msgstr "%s%s: no es posible configurar la opción \"nonblock\" para el socket"
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s%s: tiempo de espera máximo para \"%s\" con %s"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr "%s%s: error al crear el set de caracteres \"%s\" => \"%s\""
|
||||
|
||||
#~ msgid "%s%s: error: \"%s\""
|
||||
#~ msgstr "%s%s: error: \"%s\""
|
||||
|
||||
|
||||
@@ -6,8 +6,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"PO-Revision-Date: 2009-12-18 19:36+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-12-31 18:57+0100\n"
|
||||
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
@@ -3988,6 +3988,13 @@ msgstr ""
|
||||
"%s%s: attention: le serveur \"%s\" n'a pas été trouvé dans le fichier de "
|
||||
"configuration, non supprimé en mémoire car il est en cours d'utilisation"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr "tampon utilisé pour afficher le message reçu du serveur IRC"
|
||||
|
||||
#, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: erreur de création \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4152,6 +4159,13 @@ msgstr ""
|
||||
"nom de l'objet de barre où est affiché le serveur IRC (pour la barre de "
|
||||
"statut)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
"tampon cible par défaut pour les options msgbuffer quand la cible est "
|
||||
"\"private\" et que le tampon privé n'est pas trouvé"
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
|
||||
@@ -12,7 +12,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-09-20 13:51+0200\n"
|
||||
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3843,6 +3843,13 @@ msgid ""
|
||||
"memory because it's currently used"
|
||||
msgstr ""
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s nincs elég memória az információs pult üzenethez\n"
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4004,6 +4011,11 @@ msgstr ""
|
||||
msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5806,6 +5818,10 @@ msgstr "%s DCC: nem sikerült 'nonblock' opciót beállítani a csatornán\n"
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s hiányzó argumentum a(z) \"%s\" opciónak\n"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr "%s nincs elég memória az információs pult üzenethez\n"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error: \"%s\""
|
||||
#~ msgstr "%sSzerver: %s%s\n"
|
||||
|
||||
@@ -8,7 +8,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: Weechat 0.31-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-12-17 08:27+0100\n"
|
||||
"Last-Translator: Marco Paolone <marcopaolone@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3962,6 +3962,13 @@ msgstr ""
|
||||
"%s%s: attenzione: il server \"%s\" non è stato trovato nel file di "
|
||||
"configurazione, e non è stato eliminato perché è attivo"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: errore nella creazione del CTCP \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4123,6 +4130,11 @@ msgstr ""
|
||||
"nome dell'elemento barra dov'è visualizzato il server IRC (per la barra di "
|
||||
"stato)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5946,3 +5958,8 @@ msgstr "%s%s: impossibile impostare l'opzione \"nonblock\" per il socket"
|
||||
#, c-format
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s%s: timeout per \"%s\" con %s"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr ""
|
||||
#~ "%s%s: errore durante la creazione del set di caratteri \"%s\" => \"%s\""
|
||||
|
||||
@@ -9,7 +9,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-09-06 21:25+0200\n"
|
||||
"Last-Translator: Krzysztof Korościk <soltys@szluug.org>\n"
|
||||
"Language-Team: Polish\n"
|
||||
@@ -3947,6 +3947,13 @@ msgstr ""
|
||||
"%s%s: ostrzeżenie: serwer \"%s\" nie znaleziony w pliku konfiguracyjnym, nie "
|
||||
"usunięty z pamięci, ponieważ jest obecnie uzywany"
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s%s: błąd podczas tworzenia aliasu \"%s\" => \"%s\""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4104,6 +4111,11 @@ msgstr ""
|
||||
msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr "nazwa paska, w którym wyświetlany jest serwer IRC (dla paska stanu)"
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5926,6 +5938,11 @@ msgstr "%s%s: nie można ustawić opcji \"nonblock\" dla gniazda"
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s%s: przekroczono czas na \"%s\" z %s"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr ""
|
||||
#~ "%s%s: błąd przy tworzeniu zestawu znaków (kodowania) \"%s\" => \"%s\""
|
||||
|
||||
#~ msgid "%s%s: error: \"%s\""
|
||||
#~ msgstr "%s%s: błąd: \"%s\""
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.3.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: 2009-09-20 13:50+0200\n"
|
||||
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3844,6 +3844,13 @@ msgid ""
|
||||
"memory because it's currently used"
|
||||
msgstr ""
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr "%s недостаточно памяти для сообщения в строке информации\n"
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -4005,6 +4012,11 @@ msgstr ""
|
||||
msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
@@ -5804,6 +5816,10 @@ msgstr "%s DCC: не могу установить неблокирующий р
|
||||
msgid "%s%s: timeout for \"%s\" with %s"
|
||||
msgstr "%s нет аргумента для параметра \"%s\"\n"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error creating msgbuffer \"%s\" => \"%s\""
|
||||
#~ msgstr "%s недостаточно памяти для сообщения в строке информации\n"
|
||||
|
||||
#, fuzzy
|
||||
#~ msgid "%s%s: error: \"%s\""
|
||||
#~ msgstr "%sСервер: %s%s\n"
|
||||
|
||||
@@ -132,6 +132,8 @@ SET(WEECHAT_SOURCES
|
||||
./src/plugins/irc/irc-input.h
|
||||
./src/plugins/irc/irc-mode.c
|
||||
./src/plugins/irc/irc-mode.h
|
||||
./src/plugins/irc/irc-msgbuffer.c
|
||||
./src/plugins/irc/irc-msgbuffer.h
|
||||
./src/plugins/irc/irc-nick.c
|
||||
./src/plugins/irc/irc-nick.h
|
||||
./src/plugins/irc/irc-protocol.c
|
||||
|
||||
+13
-1
@@ -7,7 +7,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2009-12-18 19:35+0100\n"
|
||||
"POT-Creation-Date: 2009-12-31 00:57+0100\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
@@ -3267,6 +3267,13 @@ msgid ""
|
||||
"memory because it's currently used"
|
||||
msgstr ""
|
||||
|
||||
msgid "buffer used to display message received from IRC server"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid "%s%s: error creating \"%s\" => \"%s\""
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"format for CTCP reply or empty string for blocking CTCP (no reply), "
|
||||
"following variables are replaced: $version (WeeChat version), $compilation "
|
||||
@@ -3403,6 +3410,11 @@ msgstr ""
|
||||
msgid "name of bar item where IRC server is displayed (for status bar)"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"default target buffer for msgbuffer options when target is private and that "
|
||||
"private buffer is not found"
|
||||
msgstr ""
|
||||
|
||||
msgid ""
|
||||
"number of IRC raw messages to save in memory when raw data buffer is closed "
|
||||
"(messages will be displayed when opening raw data buffer)"
|
||||
|
||||
@@ -30,6 +30,7 @@ irc-ignore.c irc-ignore.h
|
||||
irc-info.c irc-info.h
|
||||
irc-input.c irc-input.h
|
||||
irc-mode.c irc-mode.h
|
||||
irc-msgbuffer.c irc-msgbuffer.h
|
||||
irc-nick.c irc-nick.h
|
||||
irc-protocol.c irc-protocol.h
|
||||
irc-raw.c irc-raw.h
|
||||
|
||||
@@ -50,6 +50,8 @@ irc_la_SOURCES = irc.c \
|
||||
irc-input.h \
|
||||
irc-mode.c \
|
||||
irc-mode.h \
|
||||
irc-msgbuffer.c \
|
||||
irc-msgbuffer.h \
|
||||
irc-nick.c \
|
||||
irc-nick.h \
|
||||
irc-protocol.c \
|
||||
|
||||
@@ -32,12 +32,14 @@
|
||||
#include "irc-ctcp.h"
|
||||
#include "irc-buffer.h"
|
||||
#include "irc-ignore.h"
|
||||
#include "irc-msgbuffer.h"
|
||||
#include "irc-nick.h"
|
||||
#include "irc-server.h"
|
||||
#include "irc-channel.h"
|
||||
|
||||
|
||||
struct t_config_file *irc_config_file = NULL;
|
||||
struct t_config_section *irc_config_section_msgbuffer = NULL;
|
||||
struct t_config_section *irc_config_section_ctcp = NULL;
|
||||
struct t_config_section *irc_config_section_server_default = NULL;
|
||||
struct t_config_section *irc_config_section_server = NULL;
|
||||
@@ -59,6 +61,7 @@ struct t_config_option *irc_config_look_display_old_topic;
|
||||
struct t_config_option *irc_config_look_hide_nickserv_pwd;
|
||||
struct t_config_option *irc_config_look_highlight_tags;
|
||||
struct t_config_option *irc_config_look_item_display_server;
|
||||
struct t_config_option *irc_config_look_msgbuffer_fallback;
|
||||
struct t_config_option *irc_config_look_notice_as_pv;
|
||||
struct t_config_option *irc_config_look_raw_messages;
|
||||
struct t_config_option *irc_config_look_show_away_once;
|
||||
@@ -554,6 +557,72 @@ irc_config_reload (void *data, struct t_config_file *config_file)
|
||||
return rc;
|
||||
}
|
||||
|
||||
/*
|
||||
* irc_config_msgbuffer_create_option: set a message target buffer
|
||||
*/
|
||||
|
||||
int
|
||||
irc_config_msgbuffer_create_option (void *data,
|
||||
struct t_config_file *config_file,
|
||||
struct t_config_section *section,
|
||||
const char *option_name, const char *value)
|
||||
{
|
||||
struct t_config_option *ptr_option;
|
||||
int rc;
|
||||
const char *pos_name;
|
||||
|
||||
/* make C compiler happy */
|
||||
(void) data;
|
||||
|
||||
rc = WEECHAT_CONFIG_OPTION_SET_ERROR;
|
||||
|
||||
if (option_name)
|
||||
{
|
||||
ptr_option = weechat_config_search_option (config_file, section,
|
||||
option_name);
|
||||
if (ptr_option)
|
||||
{
|
||||
if (value)
|
||||
rc = weechat_config_option_set (ptr_option, value, 1);
|
||||
else
|
||||
{
|
||||
weechat_config_option_free (ptr_option);
|
||||
rc = WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (value)
|
||||
{
|
||||
pos_name = strchr (option_name, '.');
|
||||
pos_name = (pos_name) ? pos_name + 1 : option_name;
|
||||
|
||||
ptr_option = weechat_config_new_option (
|
||||
config_file, section,
|
||||
option_name, "integer",
|
||||
_("buffer used to display message received from IRC "
|
||||
"server"),
|
||||
"weechat|current|private", 0, 0, value, value, 0,
|
||||
NULL, NULL, NULL, NULL, NULL, NULL);
|
||||
rc = (ptr_option) ?
|
||||
WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE : WEECHAT_CONFIG_OPTION_SET_ERROR;
|
||||
}
|
||||
else
|
||||
rc = WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE;
|
||||
}
|
||||
}
|
||||
|
||||
if (rc == WEECHAT_CONFIG_OPTION_SET_ERROR)
|
||||
{
|
||||
weechat_printf (NULL,
|
||||
_("%s%s: error creating \"%s\" => \"%s\""),
|
||||
weechat_prefix ("error"), IRC_PLUGIN_NAME,
|
||||
option_name, value);
|
||||
}
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
/*
|
||||
* irc_config_ctcp_create_option: set a ctcp reply format
|
||||
*/
|
||||
@@ -1322,6 +1391,13 @@ irc_config_init ()
|
||||
N_("name of bar item where IRC server is displayed (for status bar)"),
|
||||
"buffer_plugin|buffer_name", 0, 0, "buffer_plugin", NULL, 0, NULL, NULL,
|
||||
&irc_config_change_look_item_display_server, NULL, NULL, NULL);
|
||||
irc_config_look_msgbuffer_fallback = weechat_config_new_option (
|
||||
irc_config_file, ptr_section,
|
||||
"msgbuffer_fallback", "integer",
|
||||
N_("default target buffer for msgbuffer options when target is "
|
||||
"private and that private buffer is not found"),
|
||||
"current|server", 0, 0, "current", NULL, 0, NULL, NULL,
|
||||
NULL, NULL, NULL, NULL);
|
||||
irc_config_look_raw_messages = weechat_config_new_option (
|
||||
irc_config_file, ptr_section,
|
||||
"raw_messages", "integer",
|
||||
@@ -1487,6 +1563,20 @@ irc_config_init ()
|
||||
NULL, 0, 0, "off", NULL, 0, NULL, NULL,
|
||||
&irc_config_change_network_send_unknown_commands, NULL, NULL, NULL);
|
||||
|
||||
/* msgbuffer */
|
||||
ptr_section = weechat_config_new_section (irc_config_file, "msgbuffer",
|
||||
1, 1,
|
||||
NULL, NULL, NULL, NULL,
|
||||
NULL, NULL,
|
||||
&irc_config_msgbuffer_create_option, NULL,
|
||||
NULL, NULL);
|
||||
if (!ptr_section)
|
||||
{
|
||||
weechat_config_free (irc_config_file);
|
||||
return 0;
|
||||
}
|
||||
irc_config_section_msgbuffer = ptr_section;
|
||||
|
||||
/* CTCP */
|
||||
ptr_section = weechat_config_new_section (irc_config_file, "ctcp",
|
||||
1, 1,
|
||||
@@ -1499,7 +1589,6 @@ irc_config_init ()
|
||||
weechat_config_free (irc_config_file);
|
||||
return 0;
|
||||
}
|
||||
|
||||
irc_config_section_ctcp = ptr_section;
|
||||
|
||||
/* ignore */
|
||||
@@ -1526,7 +1615,6 @@ irc_config_init ()
|
||||
weechat_config_free (irc_config_file);
|
||||
return 0;
|
||||
}
|
||||
|
||||
irc_config_section_server_default = ptr_section;
|
||||
|
||||
irc_config_server_create_default_options (ptr_section);
|
||||
@@ -1544,7 +1632,6 @@ irc_config_init ()
|
||||
weechat_config_free (irc_config_file);
|
||||
return 0;
|
||||
}
|
||||
|
||||
irc_config_section_server = ptr_section;
|
||||
|
||||
hook_config_color_nicks_number = weechat_hook_config ("weechat.look.color_nicks_number",
|
||||
|
||||
@@ -35,6 +35,12 @@ enum t_irc_config_look_item_display_server
|
||||
IRC_CONFIG_LOOK_ITEM_DISPLAY_SERVER_NAME,
|
||||
};
|
||||
|
||||
enum t_irc_config_look_msgbuffer_fallback
|
||||
{
|
||||
IRC_CONFIG_LOOK_MSGBUFFER_FALLBACK_CURRENT = 0,
|
||||
IRC_CONFIG_LOOK_MSGBUFFER_FALLBACK_SERVER,
|
||||
};
|
||||
|
||||
enum t_irc_config_look_notice_as_pv
|
||||
{
|
||||
IRC_CONFIG_LOOK_NOTICE_AS_PV_AUTO = 0,
|
||||
@@ -57,6 +63,7 @@ enum t_irc_config_display_away
|
||||
};
|
||||
|
||||
extern struct t_config_file *irc_config_file;
|
||||
extern struct t_config_section *irc_config_section_msgbuffer;
|
||||
extern struct t_config_section *irc_config_section_ctcp;
|
||||
extern struct t_config_section *irc_config_section_server_default;
|
||||
extern struct t_config_section *irc_config_section_server;
|
||||
@@ -76,6 +83,7 @@ extern struct t_config_option *irc_config_look_display_old_topic;
|
||||
extern struct t_config_option *irc_config_look_hide_nickserv_pwd;
|
||||
extern struct t_config_option *irc_config_look_highlight_tags;
|
||||
extern struct t_config_option *irc_config_look_item_display_server;
|
||||
extern struct t_config_option *irc_config_look_msgbuffer_fallback;
|
||||
extern struct t_config_option *irc_config_look_notice_as_pv;
|
||||
extern struct t_config_option *irc_config_look_raw_messages;
|
||||
extern struct t_config_option *irc_config_look_show_away_once;
|
||||
|
||||
@@ -0,0 +1,142 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2009 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/* irc-msgbuffer.c: target buffer for IRC messages
|
||||
(weechat, current, private) */
|
||||
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <sys/time.h>
|
||||
#include <time.h>
|
||||
#include <sys/utsname.h>
|
||||
|
||||
#include "../weechat-plugin.h"
|
||||
#include "irc.h"
|
||||
#include "irc-msgbuffer.h"
|
||||
#include "irc-channel.h"
|
||||
#include "irc-config.h"
|
||||
#include "irc-server.h"
|
||||
|
||||
|
||||
char *irc_msgbuffer_target_string[] =
|
||||
{ "weechat", "server", "current", "private" };
|
||||
|
||||
|
||||
/*
|
||||
* irc_msgbuffer_get_string: get string value for target
|
||||
*/
|
||||
|
||||
const char *
|
||||
irc_msgbuffer_get_string (int target)
|
||||
{
|
||||
if ((target < 0) || (target >= IRC_MSGBUFFER_NUM_TARGETS))
|
||||
return NULL;
|
||||
|
||||
return irc_msgbuffer_target_string[target];
|
||||
}
|
||||
|
||||
/*
|
||||
* irc_msgbuffer_get_option: get pointer to option with IRC message
|
||||
*/
|
||||
|
||||
struct t_config_option *
|
||||
irc_msgbuffer_get_option (struct t_irc_server *server, const char *message)
|
||||
{
|
||||
struct t_config_option *ptr_option;
|
||||
char option_name[512];
|
||||
|
||||
if (server)
|
||||
{
|
||||
snprintf (option_name, sizeof (option_name),
|
||||
"%s.%s", server->name, message);
|
||||
|
||||
/* search for msgbuffer in config file, for server */
|
||||
ptr_option = weechat_config_search_option (irc_config_file,
|
||||
irc_config_section_msgbuffer,
|
||||
option_name);
|
||||
if (ptr_option)
|
||||
return ptr_option;
|
||||
}
|
||||
|
||||
/* search for msgbuffer in config file */
|
||||
ptr_option = weechat_config_search_option (irc_config_file,
|
||||
irc_config_section_msgbuffer,
|
||||
message);
|
||||
if (ptr_option)
|
||||
return ptr_option;
|
||||
|
||||
/* no msgbuffer found in config */
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* irc_msgbuffer_get_target_buffer: get target for IRC message
|
||||
* message is IRC message
|
||||
* (for example: "invite", "312")
|
||||
* alias is optional alias for message
|
||||
* (for example "whois")
|
||||
*/
|
||||
|
||||
struct t_gui_buffer *
|
||||
irc_msgbuffer_get_target_buffer (struct t_irc_server *server, const char *nick,
|
||||
const char *message, const char *alias)
|
||||
{
|
||||
struct t_config_option *ptr_option;
|
||||
int target;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
struct t_irc_channel *ptr_channel;
|
||||
struct t_weechat_plugin *buffer_plugin;
|
||||
|
||||
ptr_option = irc_msgbuffer_get_option (server, message);
|
||||
if (!ptr_option && alias && alias[0])
|
||||
ptr_option = irc_msgbuffer_get_option (server, alias);
|
||||
|
||||
target = (ptr_option) ?
|
||||
weechat_config_integer (ptr_option) : -1;
|
||||
|
||||
switch (target)
|
||||
{
|
||||
case IRC_MSGBUFFER_TARGET_WEECHAT:
|
||||
return NULL;
|
||||
break;
|
||||
case IRC_MSGBUFFER_TARGET_CURRENT:
|
||||
break;
|
||||
case IRC_MSGBUFFER_TARGET_PRIVATE:
|
||||
ptr_channel = irc_channel_search (server, nick);
|
||||
if (ptr_channel)
|
||||
return ptr_channel->buffer;
|
||||
if (weechat_config_integer (irc_config_look_msgbuffer_fallback) ==
|
||||
IRC_CONFIG_LOOK_MSGBUFFER_FALLBACK_SERVER)
|
||||
{
|
||||
return (server) ? server->buffer : NULL;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
return (server) ? server->buffer : NULL;
|
||||
break;
|
||||
}
|
||||
|
||||
ptr_buffer = weechat_current_buffer ();
|
||||
buffer_plugin = weechat_buffer_get_pointer (ptr_buffer, "plugin");
|
||||
if (buffer_plugin == weechat_irc_plugin)
|
||||
return ptr_buffer;
|
||||
return (server) ? server->buffer : NULL;
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2009 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_IRC_MSGBUFFER_H
|
||||
#define __WEECHAT_IRC_MSGBUFFER_H 1
|
||||
|
||||
enum t_irc_msgbuffer_target
|
||||
{
|
||||
IRC_MSGBUFFER_TARGET_WEECHAT = 0,
|
||||
IRC_MSGBUFFER_TARGET_CURRENT,
|
||||
IRC_MSGBUFFER_TARGET_PRIVATE,
|
||||
/* number of msgbuffer targets */
|
||||
IRC_MSGBUFFER_NUM_TARGETS,
|
||||
};
|
||||
|
||||
struct t_irc_server;
|
||||
|
||||
struct t_irc_msgbuffer
|
||||
{
|
||||
char *message; /* IRC message */
|
||||
enum t_irc_msgbuffer_target target; /* target buffer */
|
||||
};
|
||||
|
||||
extern const char *irc_msgbuffer_get_string (int target);
|
||||
extern struct t_gui_buffer *irc_msgbuffer_get_target_buffer (struct t_irc_server *server,
|
||||
const char *nick,
|
||||
const char *message,
|
||||
const char *alias);
|
||||
|
||||
#endif /* irc-msgbuffer.h */
|
||||
+121
-41
@@ -35,15 +35,16 @@
|
||||
#include "irc.h"
|
||||
#include "irc-protocol.h"
|
||||
#include "irc-buffer.h"
|
||||
#include "irc-channel.h"
|
||||
#include "irc-color.h"
|
||||
#include "irc-command.h"
|
||||
#include "irc-config.h"
|
||||
#include "irc-ctcp.h"
|
||||
#include "irc-server.h"
|
||||
#include "irc-channel.h"
|
||||
#include "irc-nick.h"
|
||||
#include "irc-mode.h"
|
||||
#include "irc-ignore.h"
|
||||
#include "irc-mode.h"
|
||||
#include "irc-msgbuffer.h"
|
||||
#include "irc-nick.h"
|
||||
#include "irc-server.h"
|
||||
|
||||
|
||||
/*
|
||||
@@ -289,7 +290,8 @@ irc_protocol_cmd_invite (struct t_irc_server *server, const char *command,
|
||||
|
||||
if (!irc_ignore_check (server, NULL, nick, host))
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, nick,
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "notify_highlight"),
|
||||
_("%sYou have been invited to %s%s%s by "
|
||||
"%s%s%s"),
|
||||
@@ -765,6 +767,7 @@ irc_protocol_cmd_notice (struct t_irc_server *server, const char *command,
|
||||
struct t_irc_channel *ptr_channel;
|
||||
struct t_irc_nick *ptr_nick;
|
||||
int notify_private;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
/* NOTICE message looks like:
|
||||
NOTICE AUTH :*** Looking up your hostname...
|
||||
@@ -861,9 +864,11 @@ irc_protocol_cmd_notice (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, nick,
|
||||
command, NULL);
|
||||
if (address && address[0])
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL),
|
||||
"%s%s%s %s(%s%s%s)%s: %s",
|
||||
@@ -881,7 +886,7 @@ irc_protocol_cmd_notice (struct t_irc_server *server, const char *command,
|
||||
{
|
||||
if (nick && nick[0])
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL),
|
||||
"%s%s%s%s: %s",
|
||||
@@ -893,7 +898,7 @@ irc_protocol_cmd_notice (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL),
|
||||
"%s%s",
|
||||
@@ -1393,7 +1398,8 @@ irc_protocol_cmd_numeric (struct t_irc_server *server, const char *command,
|
||||
pos_args = (argv_eol[2][0] == ':') ? argv_eol[2] + 1 : argv_eol[2];
|
||||
}
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1523,7 +1529,8 @@ irc_protocol_cmd_wallops (struct t_irc_server *server, const char *command,
|
||||
|
||||
if (!irc_ignore_check (server, NULL, nick, host))
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, nick,
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, NULL),
|
||||
_("%sWallops from %s%s %s(%s%s%s)%s: %s"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -1674,7 +1681,8 @@ irc_protocol_cmd_221 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(4);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[2],
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%sUser mode for %s%s%s is %s[%s%s%s]"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -1760,7 +1768,8 @@ irc_protocol_cmd_303 (struct t_irc_server *server, const char *command,
|
||||
/* make C compiler happy */
|
||||
(void) argv;
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%sUsers online: %s%s"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -1789,7 +1798,8 @@ irc_protocol_cmd_305 (struct t_irc_server *server, const char *command,
|
||||
|
||||
if (argc > 3)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "unaway"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1823,7 +1833,8 @@ irc_protocol_cmd_306 (struct t_irc_server *server, const char *command,
|
||||
|
||||
if (argc > 3)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "away"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1852,7 +1863,37 @@ irc_protocol_cmd_whois_nick_msg (struct t_irc_server *server, const char *comman
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(5);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] %s%s",
|
||||
weechat_prefix ("network"),
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_CHAT_NICK,
|
||||
argv[3],
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_CHAT,
|
||||
(argv_eol[4][0] == ':') ? argv_eol[4] + 1 : argv_eol[4]);
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
/*
|
||||
* irc_protocol_cmd_whowas_nick_msg: a whowas command with nick and message
|
||||
*/
|
||||
|
||||
int
|
||||
irc_protocol_cmd_whowas_nick_msg (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
/* messages look like:
|
||||
:server 369 flashy FlashCode :some text here
|
||||
*/
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(5);
|
||||
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whowas"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] %s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1880,7 +1921,8 @@ irc_protocol_cmd_311 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(8);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] (%s%s@%s%s)%s: %s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1912,7 +1954,8 @@ irc_protocol_cmd_312 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(6);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] %s%s %s(%s%s%s)",
|
||||
weechat_prefix ("network"),
|
||||
@@ -1944,7 +1987,8 @@ irc_protocol_cmd_314 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(8);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whowas"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%s%s[%s%s%s] (%s%s@%s%s)%s was %s"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -1985,7 +2029,8 @@ irc_protocol_cmd_315 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "who"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s]%s %s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2010,6 +2055,7 @@ irc_protocol_cmd_317 (struct t_irc_server *server, const char *command,
|
||||
{
|
||||
int idle_time, day, hour, min, sec;
|
||||
time_t datetime;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
/* 317 message looks like:
|
||||
:server 317 mynick nick 122877 1205327880 :seconds idle, signon time
|
||||
@@ -2028,9 +2074,12 @@ irc_protocol_cmd_317 (struct t_irc_server *server, const char *command,
|
||||
|
||||
datetime = (time_t)(atol (argv[5]));
|
||||
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois");
|
||||
|
||||
if (day > 0)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%s%s[%s%s%s]%s idle: %s%d %s%s, "
|
||||
"%s%02d %s%s %s%02d %s%s %s%02d "
|
||||
@@ -2062,7 +2111,7 @@ irc_protocol_cmd_317 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%s%s[%s%s%s]%s idle: %s%02d %s%s "
|
||||
"%s%02d %s%s %s%02d %s%s, "
|
||||
@@ -2111,7 +2160,8 @@ irc_protocol_cmd_321 (struct t_irc_server *server, const char *command,
|
||||
pos_args = (argc > 4) ?
|
||||
((argv_eol[4][0] == ':') ? argv_eol[4] + 1 : argv_eol[4]) : NULL;
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "list"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2144,7 +2194,8 @@ irc_protocol_cmd_322 (struct t_irc_server *server, const char *command,
|
||||
if (!server->cmd_list_regexp ||
|
||||
(regexec (server->cmd_list_regexp, argv[3], 0, NULL, 0) == 0))
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "list"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s%s%s(%s%s%s)%s%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2184,7 +2235,8 @@ irc_protocol_cmd_323 (struct t_irc_server *server, const char *command,
|
||||
pos_args = (argc > 3) ?
|
||||
((argv_eol[3][0] == ':') ? argv_eol[3] + 1 : argv_eol[3]) : NULL;
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "list"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2242,16 +2294,20 @@ irc_protocol_cmd_327 (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
char *pos_realname;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
/* 327 message looks like:
|
||||
:server 327 mynick nick host ip :real hostname/ip
|
||||
*/
|
||||
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(6);
|
||||
|
||||
pos_realname = (argc > 6) ?
|
||||
((argv_eol[6][0] == ':') ? argv_eol[6] + 1 : argv_eol[6]) : NULL;
|
||||
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois");
|
||||
|
||||
if (pos_realname && pos_realname[0])
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
@@ -2384,7 +2440,8 @@ irc_protocol_cmd_330 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(6);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] %s%s %s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2549,7 +2606,8 @@ irc_protocol_cmd_338 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(6);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[3],
|
||||
command, "whois"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s]%s %s %s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2582,7 +2640,8 @@ irc_protocol_cmd_341 (struct t_irc_server *server, const char *command,
|
||||
/* make C compiler happy */
|
||||
(void) argv_eol;
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, argv[2],
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%s%s%s%s has invited %s%s%s to %s%s%s"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -2613,7 +2672,8 @@ irc_protocol_cmd_344 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(5);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "reop"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
_("%sChannel reop %s%s%s: %s%s"),
|
||||
weechat_prefix ("network"),
|
||||
@@ -2640,7 +2700,8 @@ irc_protocol_cmd_345 (struct t_irc_server *server, const char *command,
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(5);
|
||||
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "reop"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s%s%s: %s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2767,15 +2828,19 @@ int
|
||||
irc_protocol_cmd_351 (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
/* 351 message looks like:
|
||||
:server 351 mynick dancer-ircd-1.0.36(2006/07/23_13:11:50). server :iMZ dncrTS/v4
|
||||
*/
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(5);
|
||||
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, NULL, command, NULL);
|
||||
|
||||
if (argc > 5)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s %s (%s)",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2785,7 +2850,7 @@ irc_protocol_cmd_351 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s %s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -2848,7 +2913,8 @@ irc_protocol_cmd_352 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, "who"),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s[%s%s%s] %s%s%s(%s%s@%s%s)%s "
|
||||
"%s%s%s%s(%s)",
|
||||
@@ -3273,11 +3339,15 @@ irc_protocol_cmd_432 (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
int i, nick_found, nick_to_use;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
irc_protocol_cmd_error (server, command, argc, argv, argv_eol);
|
||||
|
||||
if (!server->is_connected)
|
||||
{
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL);
|
||||
|
||||
nick_found = -1;
|
||||
nick_to_use = -1;
|
||||
for (i = 0; i < server->nicks_count; i++)
|
||||
@@ -3297,7 +3367,7 @@ irc_protocol_cmd_432 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
if (nick_to_use < 0)
|
||||
{
|
||||
weechat_printf (server->buffer,
|
||||
weechat_printf (ptr_buffer,
|
||||
_("%s%s: all declared nicknames are "
|
||||
"already in use or invalid, closing "
|
||||
"connection with server"),
|
||||
@@ -3307,7 +3377,7 @@ irc_protocol_cmd_432 (struct t_irc_server *server, const char *command,
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
weechat_printf (server->buffer,
|
||||
weechat_printf (ptr_buffer,
|
||||
_("%s%s: nickname \"%s\" is invalid, "
|
||||
"trying nickname #%d (\"%s\")"),
|
||||
weechat_prefix ("error"),
|
||||
@@ -3331,9 +3401,13 @@ irc_protocol_cmd_433 (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
int i, nick_found, nick_to_use;
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
if (!server->is_connected)
|
||||
{
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL);
|
||||
|
||||
nick_found = -1;
|
||||
nick_to_use = -1;
|
||||
for (i = 0; i < server->nicks_count; i++)
|
||||
@@ -3353,7 +3427,7 @@ irc_protocol_cmd_433 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
if (nick_to_use < 0)
|
||||
{
|
||||
weechat_printf (server->buffer,
|
||||
weechat_printf (ptr_buffer,
|
||||
_("%s%s: all declared nicknames are "
|
||||
"already in use, closing "
|
||||
"connection with server"),
|
||||
@@ -3363,7 +3437,7 @@ irc_protocol_cmd_433 (struct t_irc_server *server, const char *command,
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
weechat_printf (server->buffer,
|
||||
weechat_printf (ptr_buffer,
|
||||
_("%s: nickname \"%s\" is already in use, "
|
||||
"trying nickname #%d (\"%s\")"),
|
||||
IRC_PLUGIN_NAME, server->nick,
|
||||
@@ -3389,15 +3463,20 @@ int
|
||||
irc_protocol_cmd_438 (struct t_irc_server *server, const char *command,
|
||||
int argc, char **argv, char **argv_eol)
|
||||
{
|
||||
struct t_gui_buffer *ptr_buffer;
|
||||
|
||||
/* 438 message looks like:
|
||||
:server 438 mynick newnick :Nick change too fast. Please wait 30 seconds.
|
||||
*/
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(4);
|
||||
|
||||
ptr_buffer = irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL);
|
||||
|
||||
if (argc >= 5)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s (%s => %s)",
|
||||
weechat_prefix ("network"),
|
||||
@@ -3407,7 +3486,7 @@ irc_protocol_cmd_438 (struct t_irc_server *server, const char *command,
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (ptr_buffer,
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s %s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -3434,7 +3513,8 @@ irc_protocol_cmd_901 (struct t_irc_server *server, const char *command,
|
||||
|
||||
if (argc >= 7)
|
||||
{
|
||||
weechat_printf_tags (server->buffer,
|
||||
weechat_printf_tags (irc_msgbuffer_get_target_buffer (server, NULL,
|
||||
command, NULL),
|
||||
irc_protocol_tags (command, "irc_numeric"),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
@@ -3541,7 +3621,7 @@ irc_protocol_recv_command (struct t_irc_server *server, const char *entire_line,
|
||||
{ "366", /* end of /names list */ 1, &irc_protocol_cmd_366 },
|
||||
{ "367", /* banlist */ 1, &irc_protocol_cmd_367 },
|
||||
{ "368", /* end of banlist */ 1, &irc_protocol_cmd_368 },
|
||||
{ "369", /* whowas (end) */ 1, &irc_protocol_cmd_whois_nick_msg },
|
||||
{ "369", /* whowas (end) */ 1, &irc_protocol_cmd_whowas_nick_msg },
|
||||
{ "378", /* whois (connecting from) */ 1, &irc_protocol_cmd_whois_nick_msg },
|
||||
{ "379", /* whois (using modes) */ 1, &irc_protocol_cmd_whois_nick_msg },
|
||||
{ "401", /* no such nick/channel */ 1, &irc_protocol_cmd_error },
|
||||
|
||||
Reference in New Issue
Block a user