mirror of
https://github.com/weechat/weechat.git
synced 2026-06-24 20:06:38 +02:00
Compare commits
77 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8ab538c0d9 | |||
| 93d472e3d0 | |||
| e226c2e147 | |||
| 890a9e54be | |||
| 15bb7656a5 | |||
| 733eb99b17 | |||
| a7ea40da2c | |||
| 068776b5a7 | |||
| ccf18f4bf6 | |||
| fc1571645d | |||
| 53a9a161f4 | |||
| 27dd6cf72f | |||
| b78b5575c3 | |||
| 4e43be6d2c | |||
| fc71ce0d43 | |||
| 9358f076a3 | |||
| 795b9c9da9 | |||
| 7a76a959ec | |||
| a6aee98cb1 | |||
| 4c871760d2 | |||
| ddd7a85f2d | |||
| a538a9c08e | |||
| 5597c93b64 | |||
| e7b604c97e | |||
| 13fc108c6d | |||
| aa8a1cc775 | |||
| 2cc265f34e | |||
| 3c3311bf17 | |||
| 124b2668fe | |||
| 5262e05177 | |||
| 6dcb1e7b10 | |||
| dbc30707aa | |||
| 8b1939059b | |||
| e13593dceb | |||
| b2466aae29 | |||
| 6a09cf0ed3 | |||
| 895a46c55f | |||
| a93c92c5b1 | |||
| b1b5a3eac9 | |||
| 21538edc9b | |||
| 1aa8fd09ef | |||
| 28cb1ae6f5 | |||
| cf3e0ccbfd | |||
| 8a93906beb | |||
| ad07527007 | |||
| 6295adad6d | |||
| e29f01b4fb | |||
| ee1e181894 | |||
| 1294bce155 | |||
| ed05730a3b | |||
| 63d9f2452d | |||
| d046315e8b | |||
| f9b04635d3 | |||
| 35574d63ab | |||
| 2987f9208e | |||
| aaa29153b0 | |||
| d2dc05b01e | |||
| 3d6b9ff5a7 | |||
| 3ffbb85cb9 | |||
| 12c8cd4988 | |||
| 7710084ba8 | |||
| 329dbefbfd | |||
| c3ec3cd3ed | |||
| ed76e7adc6 | |||
| 0693ffb82b | |||
| db01880bd1 | |||
| 16874bd4ec | |||
| f227e9ec3e | |||
| e8c03ea513 | |||
| b62705a299 | |||
| 4bebc81dcb | |||
| d9d36c8dd4 | |||
| 197cd30379 | |||
| 2331f68c88 | |||
| 8386c1a210 | |||
| 9177e02f1a | |||
| 94f12b4b8b |
@@ -11,6 +11,8 @@ env:
|
||||
before_script:
|
||||
- echo 'APT::Install-Recommends "false";' | sudo tee -a /etc/apt/apt.conf
|
||||
- sudo apt-get update -qq
|
||||
- wget http://weechat.org/files/tests/ubuntu/precise/amd64/libcpputest-dev_3.4-3_amd64.deb
|
||||
- sudo dpkg -i libcpputest-dev_3.4-3_amd64.deb
|
||||
- sudo apt-get -y install devscripts equivs python-pip libenchant-dev autopoint
|
||||
- sudo mk-build-deps -i debian/control
|
||||
- sudo pip install msgcheck pylint
|
||||
@@ -23,3 +25,6 @@ script:
|
||||
after_success:
|
||||
- weechat --help
|
||||
- weechat -r /quit
|
||||
|
||||
matrix:
|
||||
fast_finish: true
|
||||
|
||||
@@ -55,6 +55,7 @@ Alphabetically:
|
||||
* Matt Robinson
|
||||
* Mantas Mikulėnas (grawity)
|
||||
* Mateusz Poszwa
|
||||
* Max Anton Teufel
|
||||
* Murilo Opsfelder Araujo
|
||||
* Nicolas Cavigneaux
|
||||
* Nils Görs (nils_2)
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ endif()
|
||||
|
||||
# version
|
||||
set(VERSION_MAJOR "1")
|
||||
set(VERSION_MINOR "0-rc1")
|
||||
set(VERSION_MINOR "0-rc3")
|
||||
set(VERSION_PATCH "")
|
||||
if(VERSION_PATCH STREQUAL "")
|
||||
set(VERSION ${VERSION_MAJOR}.${VERSION_MINOR})
|
||||
|
||||
+20
-2
@@ -15,11 +15,18 @@ http://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
|
||||
|
||||
== Version 1.0 (under dev)
|
||||
|
||||
* core: fix zero-length malloc of an hashtable item with type "buffer"
|
||||
* core: fix memory leak on /upgrade when file signature in upgrade file is
|
||||
invalid
|
||||
* core: fix memory leak in completion of config options values
|
||||
* core: fix memory leak when removing script files
|
||||
* core: fix result of hash function (in hashtables) on 32-bit systems
|
||||
* core: add terabyte unit for size displayed
|
||||
* core: fix insert of mouse code in input line after a partial key combo
|
||||
(closes #130)
|
||||
* core: check code point value in UTF-8 check function (closes #108)
|
||||
* core: display a warning on startup if $TERM is not screen(-256color) under
|
||||
screen/tmux
|
||||
* core: display a warning on startup if $TERM does not start with "screen"
|
||||
under screen/tmux
|
||||
* core: add option "-mask" in command /unset (closes #112)
|
||||
* core: add option weechat.color.status_nicklist_count (closes #109,
|
||||
closes #110)
|
||||
@@ -99,6 +106,8 @@ http://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
|
||||
* core: display a warning in case of inconsistency between the options
|
||||
weechat.look.save_{config|layout}_on_exit
|
||||
* tests: add unit tests using CppUTest
|
||||
* api: fix function string_decode_base64
|
||||
* api: fix function string_format_size on 32-bit systems
|
||||
* api: add argument "flags" in function hdata_new_list
|
||||
* api: change type of arguments displayed/highlight in hook_print callback from
|
||||
string to integer (in scripts)
|
||||
@@ -123,6 +132,9 @@ http://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
|
||||
* alias: change default command for alias /beep to "/print -beep"
|
||||
* exec: add exec plugin: new command /exec and file exec.conf
|
||||
* guile: fix module used after unload of a script
|
||||
* irc: fix memory leak in CTCP answer
|
||||
* irc: fix duplicate sender name in display of wallops (closes #142,
|
||||
closes #145)
|
||||
* irc: display locally away status changes in private buffers (in addition to
|
||||
channels) (closes #117)
|
||||
* irc: add value "+" for option irc.look.smart_filter_mode to use modes from
|
||||
@@ -165,6 +177,11 @@ http://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
|
||||
* python: fix read of return value for callbacks returning an integer
|
||||
in Python 2.x (closes #125)
|
||||
* python: fix interpreter used after unload of a script
|
||||
* relay: fix memory leak during handshake on websocket
|
||||
* relay: fix memory leak when receiving commands from client (weechat protocol)
|
||||
* relay: fix crash when an IRC "MODE" command is received from client without
|
||||
arguments
|
||||
* relay: fix number of bytes sent/received on 32-bit systems
|
||||
* relay: fix crash when closing relay buffers (closes #57, closes #78)
|
||||
* relay: check pointers received in hdata command to prevent crashes with bad
|
||||
pointers (WeeChat protocol)
|
||||
@@ -308,6 +325,7 @@ http://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
|
||||
* irc: add option irc.look.notice_welcome_tags
|
||||
* irc: add server option "default_msg_kick" to customize default kick/kickban
|
||||
message (task #12777)
|
||||
* logger: fix memory leaks in backlog
|
||||
* logger: replace backslashs in name by logger replacement char under Cygwin
|
||||
(bug #41207)
|
||||
* lua: fix detection of Lua 5.2 in autotools (patch #8270)
|
||||
|
||||
@@ -46,6 +46,7 @@ Following packages are optional:
|
||||
* for scripting: python, perl, ruby, lua, tcl, guile
|
||||
* for building doc: asciidoc, source-highlight
|
||||
(for man page: xsltproc, docbook-xml, docbook-xsl)
|
||||
* for building tests: C++ compiler, CppUTest
|
||||
|
||||
For a complete list of dependencies and versions recommended, please look at
|
||||
http://weechat.org/files/doc/devel/weechat_user.en.html#dependencies[user's guide].
|
||||
|
||||
+5
-21
@@ -51,36 +51,20 @@ run ()
|
||||
fi
|
||||
}
|
||||
|
||||
###
|
||||
### cleanning part
|
||||
###
|
||||
# remove autotools stuff
|
||||
run "rm -rf config"
|
||||
# remove autotools stuff
|
||||
run "rm -f config.h.in"
|
||||
run "rm -f aclocal.m4 configure config.log config.status"
|
||||
run "rm -rf autom4te*.cache"
|
||||
|
||||
# remove libtool stuff
|
||||
run "rm -f libtool"
|
||||
|
||||
# remove gettext stuff
|
||||
run "rm -f ABOUT-NLS"
|
||||
run "rm -rf intl"
|
||||
|
||||
###
|
||||
### configuration part
|
||||
###
|
||||
# create the config directory
|
||||
run "mkdir -p config/m4"
|
||||
run "mkdir intl"
|
||||
|
||||
# execute autotools cmds
|
||||
run "autopoint -f"
|
||||
LIBTOOLIZE=libtoolize
|
||||
test `uname` = "Darwin" && LIBTOOLIZE=glibtoolize
|
||||
run "$LIBTOOLIZE --automake --force --copy"
|
||||
run "aclocal --force -I config/m4"
|
||||
run "autoheader"
|
||||
run "autoconf"
|
||||
run "automake --add-missing --copy --gnu"
|
||||
# execute autoreconf cmds
|
||||
run "autoreconf -fvi"
|
||||
|
||||
# ending
|
||||
rm -f $AUTOGEN_LOG
|
||||
|
||||
+1
-1
@@ -24,7 +24,7 @@
|
||||
# Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_PREREQ(2.56)
|
||||
AC_INIT(WeeChat, 1.0-rc1, flashcode@flashtux.org)
|
||||
AC_INIT(WeeChat, 1.0-rc3, flashcode@flashtux.org)
|
||||
AC_CONFIG_SRCDIR([configure.ac])
|
||||
AM_CONFIG_HEADER(config.h)
|
||||
AM_INIT_AUTOMAKE([foreign])
|
||||
|
||||
@@ -81,7 +81,7 @@ WeeChat kann mittels cmake oder autotools kompiliert werden (cmake sollte dabei
|
||||
folgende Tabelle beschreibt welche Pakete zwingend notwendig sind um WeeChat zu kompilieren und
|
||||
welche Pakete optional genutzt werden können.
|
||||
|
||||
[width="100%",cols="5,^3,^3,13",options="header"]
|
||||
[width="100%",cols="5,^3,^3,.^13",options="header"]
|
||||
|===
|
||||
| Paket ^(1)^ | Version | benötigt | Funktion
|
||||
| cmake | | *ja* | Zum kompilieren (autotools ist möglich. cmake wird aber empfohlen)
|
||||
@@ -103,9 +103,8 @@ welche Pakete optional genutzt werden können.
|
||||
| source-highlight | | | Syntax Highlight für Quelltext in Dokumentation
|
||||
| xsltproc,
|
||||
docbook-xml, docbook-xsl | | | Erstellt man page
|
||||
// TRANSLATION MISSING
|
||||
| libcpputest-dev,
|
||||
C++ compiler | | | Run tests
|
||||
| libcpputest-dev | ≥ 3.4 | .2+| Testlauf
|
||||
| C++ compiler | |
|
||||
|===
|
||||
|
||||
[NOTE]
|
||||
@@ -244,9 +243,8 @@ Liste von häufig verwendeten Optionen:
|
||||
| ENABLE_XFER | `ON`, `OFF` | ON |
|
||||
kompiliert <<xfer_plugin,Xfer Erweiterung>>.
|
||||
|
||||
// TRANSLATION MISSING
|
||||
| ENABLE_TESTS | `ON`, `OFF` | OFF |
|
||||
Compile tests.
|
||||
kompiliert Testumgebung.
|
||||
|===
|
||||
|
||||
Weitere Optionen können mit folgendem Befehl angezeigt werden:
|
||||
|
||||
@@ -1598,7 +1598,11 @@ C examples:
|
||||
----
|
||||
/* examples with English locale */
|
||||
|
||||
char *str = weechat_string_format_size (0); /* str == "0 byte" */
|
||||
char *str = weechat_string_format_size (0); /* str == "0 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1); /* str == "1 byte" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
@@ -1606,11 +1610,11 @@ char *str = weechat_string_format_size (200); /* str == "200 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1536); /* str == "1.5 KB" */
|
||||
char *str = weechat_string_format_size (15200); /* str == "15.2 KB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2 MB" */
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2.10 MB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
----
|
||||
@@ -3362,8 +3366,8 @@ Prototype:
|
||||
struct t_hashtable *weechat_hashtable_new (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
unsigned long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
unsigned long long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
int (*callback_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1,
|
||||
const void *key2));
|
||||
|
||||
@@ -80,7 +80,7 @@ WeeChat can be compiled with cmake or autotools (cmake is recommended way).
|
||||
Following table shows list of packages that are required or optional to
|
||||
compile WeeChat.
|
||||
|
||||
[width="100%",cols="5,^3,^3,13",options="header"]
|
||||
[width="100%",cols="5,^3,^3,.^13",options="header"]
|
||||
|===
|
||||
| Package ^(1)^ | Version | Required | Feature
|
||||
| cmake | | *yes* | Build (autotools still possible, but cmake is recommended)
|
||||
@@ -102,8 +102,8 @@ compile WeeChat.
|
||||
| source-highlight | | | Syntax highlight for sources in documentation
|
||||
| xsltproc,
|
||||
docbook-xml, docbook-xsl | | | Build of man page
|
||||
| libcpputest-dev,
|
||||
C++ compiler | | | Run tests
|
||||
| libcpputest-dev | ≥ 3.4 | .2+| Run tests
|
||||
| C++ compiler | |
|
||||
|===
|
||||
|
||||
[NOTE]
|
||||
|
||||
@@ -1632,15 +1632,19 @@ char *str = weechat_string_format_size (0); /* str == "0 octet" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1); /* str == "1 octet" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (200); /* str == "200 octets" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1536); /* str == "1.5 Ko" */
|
||||
char *str = weechat_string_format_size (15200); /* str == "15.2 Ko" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2 Mo" */
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2.10 Mo" */
|
||||
/* ... */
|
||||
free (str);
|
||||
----
|
||||
@@ -3411,8 +3415,8 @@ Prototype :
|
||||
struct t_hashtable *weechat_hashtable_new (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
unsigned long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
unsigned long long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
int (*callback_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1,
|
||||
const void *key2));
|
||||
|
||||
@@ -82,7 +82,7 @@ recommandée).
|
||||
Le tableau suivant liste les paquets qui sont requis ou optionnels pour
|
||||
compiler WeeChat.
|
||||
|
||||
[width="100%",cols="5,^3,^3,13",options="header"]
|
||||
[width="100%",cols="5,^3,^3,.^13",options="header"]
|
||||
|===
|
||||
| Paquet ^(1)^ | Version | Requis | Fonctionnalité
|
||||
| cmake | | *oui* | Construction (autotools toujours possible, mais cmake est recommandé)
|
||||
@@ -104,8 +104,8 @@ compiler WeeChat.
|
||||
| source-highlight | | | Coloration des sources dans la documentation
|
||||
| xsltproc,
|
||||
docbook-xml, docbook-xsl | | | Construction de la page de manuel
|
||||
| libcpputest-dev,
|
||||
compilateur C++ | | | Lancement des tests
|
||||
| libcpputest-dev | ≥ 3.4 | .2+| Lancement des tests
|
||||
| C++ compiler | |
|
||||
|===
|
||||
|
||||
[NOTE]
|
||||
|
||||
@@ -1650,7 +1650,11 @@ Esempi in C:
|
||||
----
|
||||
/* esempi in lingua inglese */
|
||||
|
||||
char *str = weechat_string_format_size (0); /* str == "0 byte" */
|
||||
char *str = weechat_string_format_size (0); /* str == "0 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1); /* str == "1 byte" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
@@ -1658,11 +1662,11 @@ char *str = weechat_string_format_size (200); /* str == "200 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1536); /* str == "1.5 KB" */
|
||||
char *str = weechat_string_format_size (15200); /* str == "15.2 KB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2 MB" */
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2.10 MB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
----
|
||||
@@ -3436,8 +3440,8 @@ Prototipo:
|
||||
struct t_hashtable *weechat_hashtable_new (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
unsigned long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
unsigned long long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
int (*callback_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1,
|
||||
const void *key2));
|
||||
|
||||
@@ -85,7 +85,7 @@ WeeChat può essere compilato con cmake oppure autotools
|
||||
La seguente tabella mostra l'elenco di pacchetti richiesti o opzionali per
|
||||
compilare WeeChat.
|
||||
|
||||
[width="100%",cols="5,^3,^3,13",options="header"]
|
||||
[width="100%",cols="5,^3,^3,.^13",options="header"]
|
||||
|===
|
||||
| Pacchetto ^(1)^ | Versione | Richiesto | Caratteristica
|
||||
| cmake | | *sì* | Compilazione (ancora possibile con autotools, ma si raccomanda cmake)
|
||||
@@ -113,8 +113,8 @@ compilare WeeChat.
|
||||
| xsltproc,
|
||||
docbook-xml, docbook-xsl | | | Build of man page
|
||||
// TRANSLATION MISSING
|
||||
| libcpputest-dev,
|
||||
C++ compiler | | | Run tests
|
||||
| libcpputest-dev | ≥ 3.4 | .2+| Run tests
|
||||
| C++ compiler | |
|
||||
|===
|
||||
|
||||
[NOTE]
|
||||
|
||||
@@ -797,15 +797,15 @@ option: オプションの名前 (ワイルドカード '*' を使うことが
|
||||
/unset <option>
|
||||
-mask <option>
|
||||
|
||||
option: name of an option
|
||||
-mask: use a mask in option (wildcard "*" is allowed to mass-reset options, use carefully!)
|
||||
option: オプションの名前
|
||||
-mask: オプション内でマスクを使う (大量のオプションをリセットするにはワイルドカード "*" を使ってください、使用に注意!)
|
||||
|
||||
According to option, it's reset (for standard options) or removed (for optional settings, like server values).
|
||||
オプションの種類によって (一般的なオプションを) リセットまたは (サーバなどの任意な設定を) 削除が行われます。
|
||||
|
||||
Examples:
|
||||
reset one option:
|
||||
例:
|
||||
オプションのリセット:
|
||||
/unset weechat.look.item_time_format
|
||||
reset all color options:
|
||||
全ての色関連オプションをリセット:
|
||||
/unset -mask weechat.color.*
|
||||
----
|
||||
|
||||
|
||||
@@ -294,7 +294,7 @@
|
||||
** 値: WeeChat の色名 (default、black、(dark)gray、white、(light)red、(light)green、brown、yellow、(light)blue、(light)magenta、(light)cyan) 、ターミナル色番号またはその別名; 色の前に属性を置くことができます (テキスト前景色のみ、背景色は出来ません): 太字は "*"、反転は "!"、イタリックは "/"、下線は "_" (デフォルト値: `lightgreen`)
|
||||
|
||||
* [[option_weechat.color.status_nicklist_count]] *weechat.color.status_nicklist_count*
|
||||
** 説明: `text color for number of nicks in nicklist (status bar)`
|
||||
** 説明: `ニックネームリスト内のニックネーム数のテキスト色 (ステータスバー)`
|
||||
** タイプ: 色
|
||||
** 値: WeeChat の色名 (default、black、(dark)gray、white、(light)red、(light)green、brown、yellow、(light)blue、(light)magenta、(light)cyan) 、ターミナル色番号またはその別名; 色の前に属性を置くことができます (テキスト前景色のみ、背景色は出来ません): 太字は "*"、反転は "!"、イタリックは "/"、下線は "_" (デフォルト値: `default`)
|
||||
|
||||
|
||||
@@ -68,12 +68,9 @@ WeeChat の主要なリポジトリは 2 つあります:
|
||||
| guile/ | guile (scheme) スクリプト用 API
|
||||
| trigger/ | trigger プラグイン
|
||||
| xfer/ | xfer (IRC DCC ファイル/チャット)
|
||||
// TRANSLATION MISSING
|
||||
| tests/ | Tests
|
||||
// TRANSLATION MISSING
|
||||
| unit/ | Unit tests
|
||||
// TRANSLATION MISSING
|
||||
| core/ | Unit tests for core functions
|
||||
| tests/ | テスト
|
||||
| unit/ | 単体テスト
|
||||
| core/ | コア関数の単体テスト
|
||||
| doc/ | 文書
|
||||
| po/ | 翻訳ファイル (gettext)
|
||||
| debian/ | Debian パッケージ用
|
||||
@@ -94,8 +91,7 @@ WeeChat "core" は以下のディレクトリに配置されています:
|
||||
|===
|
||||
| パス/ファイル名 | 説明
|
||||
| core/ | コア関数: エントリポイント、内部構造体
|
||||
// TRANSLATION MISSING
|
||||
| weechat.c | Main functions: command line options, startup
|
||||
| weechat.c | 主要関数: コマンドラインオプション、起動
|
||||
| wee-backtrace.c | クラッシュした際にバックトレースを表示
|
||||
| wee-command.c | WeeChat コアコマンド
|
||||
| wee-completion.c | デフォルト補完
|
||||
@@ -149,8 +145,7 @@ WeeChat "core" は以下のディレクトリに配置されています:
|
||||
| gui-curses-mouse.c | マウス
|
||||
| gui-curses-term.c | ターミナルについての関数
|
||||
| gui-curses-window.c | ウィンドウ
|
||||
// TRANSLATION MISSING
|
||||
| main.c | Entry point
|
||||
| main.c | エントリポイント
|
||||
|===
|
||||
|
||||
[[sources_plugins]]
|
||||
@@ -289,25 +284,23 @@ WeeChat "core" は以下のディレクトリに配置されています:
|
||||
| xfer-upgrade.c | WeeChat をアップグレードする際の xfer データの保存および回復
|
||||
|===
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[[sources_tests]]
|
||||
==== Tests
|
||||
==== テスト
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[width="100%",cols="1v,5",options="header"]
|
||||
|===
|
||||
| パス/ファイル名 | 説明
|
||||
| tests/ | Root of tests
|
||||
| unit/ | Root of unit tests
|
||||
| test-eval.cpp | Tests: evaluation of expressions
|
||||
| test-hashtble.cpp | Tests: hashtables
|
||||
| test-hdata.cpp | Tests: hdata
|
||||
| test-infolist.cpp | Tests: infolists
|
||||
| test-list.cpp | Tests: lists
|
||||
| test-string.cpp | Tests: strings
|
||||
| test-url.cpp | Tests: URLs
|
||||
| test-utf8.cpp | Tests: UTF-8
|
||||
| test-util.cpp | Tests: util functions
|
||||
| tests/ | テストのルートディレクトリ
|
||||
| unit/ | 単体テストのルートディレクトリ
|
||||
| test-eval.cpp | テスト: 式の評価
|
||||
| test-hashtble.cpp | テスト: ハッシュテーブル
|
||||
| test-hdata.cpp | テスト: hdata
|
||||
| test-infolist.cpp | テスト: インフォリスト
|
||||
| test-list.cpp | テスト: リスト
|
||||
| test-string.cpp | テスト: 文字列
|
||||
| test-url.cpp | テスト: URL
|
||||
| test-utf8.cpp | テスト: UTF-8
|
||||
| test-util.cpp | テスト: ユーティリティ関数
|
||||
|===
|
||||
|
||||
[[documentation_translations]]
|
||||
@@ -1064,5 +1057,5 @@ asciidoc ファイルは 'doc/XX/' ディレクトリにあり、'XX' は言語
|
||||
`<<link_name>>` の後に名前がある場合、これも必ず翻訳してください:
|
||||
|
||||
----
|
||||
<<link_name,this text must be translated>>
|
||||
<<link_name,このテキストは必ず翻訳してください>>
|
||||
----
|
||||
|
||||
@@ -1594,7 +1594,11 @@ C 言語での使用例:
|
||||
----
|
||||
/* examples with English locale */
|
||||
|
||||
char *str = weechat_string_format_size (0); /* str == "0 byte" */
|
||||
char *str = weechat_string_format_size (0); /* str == "0 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1); /* str == "1 byte" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
@@ -1602,11 +1606,11 @@ char *str = weechat_string_format_size (200); /* str == "200 bytes" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (1536); /* str == "1.5 KB" */
|
||||
char *str = weechat_string_format_size (15200); /* str == "15.2 KB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2 MB" */
|
||||
char *str = weechat_string_format_size (2097152); /* str == "2.10 MB" */
|
||||
/* ... */
|
||||
free (str);
|
||||
----
|
||||
@@ -3358,8 +3362,8 @@ _WeeChat バージョン 0.3.3 以上で利用可。_
|
||||
struct t_hashtable *weechat_hashtable_new (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
unsigned long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
unsigned long long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
int (*callback_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1,
|
||||
const void *key2));
|
||||
@@ -6550,8 +6554,7 @@ void weechat_printf_date_tags (struct t_gui_buffer *buffer, time_t date,
|
||||
| notify_highlight | この行を含むバッファは "highlight" レベルでホットリストに追加される
|
||||
| nick_xxx | ニックネーム "xxx" からのメッセージ
|
||||
| prefix_nick_ccc | プレフィックスを色 "ccc" のニックネームにする
|
||||
// TRANSLATION MISSING
|
||||
| host_xxx | Username and host in message
|
||||
| host_xxx | メッセージ中のユーザ名とホスト
|
||||
| irc_xxx | IRC メッセージ "xxx" (コマンドまたは 3 桁の番号)
|
||||
| irc_numeric | IRC 番号メッセージ
|
||||
| irc_error | IRC からのエラー
|
||||
|
||||
@@ -80,7 +80,7 @@ WeeChat は cmake または autotools を使ってコンパイルできます (c
|
||||
以下の表は WeeChat
|
||||
のコンパイルに必須または任意で必要なパッケージのリストです。
|
||||
|
||||
[width="100%",cols="5,^3,^3,13",options="header"]
|
||||
[width="100%",cols="5,^3,^3,.^13",options="header"]
|
||||
|===
|
||||
| パッケージ ^(1)^ | バージョン | 必須 | 機能
|
||||
| cmake | | *yes* | ビルド (autotools でも可能ですが、cmake を推奨します)
|
||||
@@ -102,9 +102,8 @@ WeeChat は cmake または autotools を使ってコンパイルできます (c
|
||||
| source-highlight | | | 文書中のソースに対するシンタックスハイライト
|
||||
| xsltproc,
|
||||
docbook-xml, docbook-xsl | | | man ページのビルド
|
||||
// TRANSLATION MISSING
|
||||
| libcpputest-dev,
|
||||
C++ compiler | | | Run tests
|
||||
| libcpputest-dev | ≥ 3.4 | .2+| テストの実行
|
||||
| C++ コンパイラ | |
|
||||
|===
|
||||
|
||||
[NOTE]
|
||||
@@ -242,9 +241,8 @@ cmake に対するオプションを指定するには、以下のフォーマ
|
||||
| ENABLE_XFER | `ON`, `OFF` | ON |
|
||||
<<xfer_plugin,Xfer プラグイン>>のコンパイル
|
||||
|
||||
// TRANSLATION MISSING
|
||||
| ENABLE_TESTS | `ON`, `OFF` | OFF |
|
||||
Compile tests.
|
||||
コンパイルテスト。
|
||||
|===
|
||||
|
||||
その他のオプションは以下のコマンドで確認してください:
|
||||
|
||||
@@ -98,8 +98,6 @@ Pełna licencja znajduje się w pliku COPYING.
|
||||
|
||||
Strona www: <http://weechat.org/>
|
||||
|
||||
// TRANSLATION MISSING
|
||||
== SUPPORT / REPORTING BUGS
|
||||
== WSPARCIE / ZGŁASZANIE BŁĘDÓW
|
||||
|
||||
// TRANSLATION MISSING
|
||||
For help or a bug report: <http://weechat.org/dev/support>
|
||||
W celu uzyskania pomocy, lub zgłoszenia błędu zajrzyj na: <http://weechat.org/dev/support>
|
||||
|
||||
@@ -35,8 +35,7 @@ Więcej informacji na stronie: http://weechat.org/about/features
|
||||
[[gui]]
|
||||
=== Słyszałem o wielu GUI dla WeeChat. Jak mogę je skompilować/użyć?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
Some remote GUIs are available, see the links on features page:
|
||||
Dostępne są zdalne interfejsy, linki można znaleźć na stronie z cechami:
|
||||
http://weechat.org/about/features
|
||||
|
||||
[[compile_git]]
|
||||
@@ -218,8 +217,7 @@ użyty w żadnym z pasków:
|
||||
[[terminal_copy_paste]]
|
||||
=== Jak mogę kopiować/wklejać tekst bez wklejania listy nicków?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
With WeeChat ≥ 1.0, you can use the bare display (default key: key[alt-l]).
|
||||
W WeeChat od wersji ≥ 1.0, możesz użyć trybu niesformatowanego wyświetlania (domyślnie: key[alt-l]).
|
||||
|
||||
Możesz użyć terminala z prostokątnym zaznaczaniem (jak rxvt-unicode,
|
||||
konsole, gnome-terminal, ...). Klawisze to zazwyczaj key[ctrl-]key[alt-] zaznaczenie myszką.
|
||||
@@ -233,8 +231,7 @@ Innym rozwiązaniem jest przesunięcie listy nicków na górę lub dół, na prz
|
||||
[[urls]]
|
||||
=== Jak mogę kliknąć na długi URL (dłuższy niż linia)?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
With WeeChat ≥ 1.0, you can use the bare display (default key: key[alt-l]).
|
||||
W WeeChat od wersji ≥ 1.0, możesz użyć trybu niesformatowanego wyświetlania (domyślnie: key[alt-l]).
|
||||
|
||||
Domyślnie WeeChat wyświetla czas i przedrostki dla każdej linii i opcjonalne paski
|
||||
dookoła obszaru rozmowy. Aby usprawnić klikanie w urle można przesunąć listę nicków
|
||||
@@ -267,16 +264,14 @@ Innym rozwiązaniem jest użycie skryptu:
|
||||
[[change_locale_without_quit]]
|
||||
=== Chcę zmienić język komunikatów wyświetlanych przez WeeChat, ale bez jego zamykania, czy jest to możliwe?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
Yes, with WeeChat ≥ 1.0:
|
||||
Tak, dla wersji WeeChat ≥ 1.0:
|
||||
|
||||
----
|
||||
/set env LANG pl_PL.UTF-8
|
||||
/upgrade
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
With older WeeChat:
|
||||
Dla starszych wersji WeeChat:
|
||||
|
||||
----
|
||||
/script install shell.py
|
||||
@@ -305,9 +300,8 @@ Jeśli używasz screena, możesz dodać to do swojego '~/.screenrc':
|
||||
term screen-256color
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
If your 'TERM' variable has wrong value and that WeeChat is already running,
|
||||
you can change it with these two commands (with WeeChat ≥ 1.0):
|
||||
Jeśli twoja zmienna 'TERM' posiada złą wartość i WeeChat jest już uruchomiony,
|
||||
możesz zmienić ją za pomocą tych dwóch komend (dla wersji Weechat ≥ 1.0):
|
||||
|
||||
----
|
||||
/set env TERM screen-256color
|
||||
@@ -330,25 +324,24 @@ Poruszanie się między podświetleniami: key[alt-p] / key[alt-n].
|
||||
|
||||
Po więcej informacji zajrzyj do poradnika użytkownika (domyślne skróty klawiszowe).
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[[terminal_focus]]
|
||||
=== How can I execute commands when terminal gets/loses focus?
|
||||
=== Jak mogę wykonywać komendy, kiedy terminal stanie się/przestanie być aktywny?
|
||||
|
||||
You must enable the focus events with a special code sent to terminal.
|
||||
Musisz włączyć obsługę tego zdarzenia za pomocą specjalnego kodu wysyłanego do terminala.
|
||||
|
||||
*Important*:
|
||||
*Ważne*:
|
||||
|
||||
* Currently, *only* 'xterm' seems to support this feature.
|
||||
* It does *not* work under screen/tmux.
|
||||
* Obecnie *tylko* 'xterm' wspiera tą funkcję.
|
||||
* *Nie* działa to pod screen/tmux.
|
||||
|
||||
To send the code when WeeChat is starting:
|
||||
Żeby wysłać kod podczas uruchamiania WeeChat:
|
||||
|
||||
----
|
||||
/set weechat.startup.command_after_plugins "/print -stdout \033[?1004h\n"
|
||||
----
|
||||
|
||||
And then you bind two keys for the focus (replace the `/print` commands by the
|
||||
commands of your choice):
|
||||
Następnie przypisz dwie kombinacje klawiszy dla stanu aktywności (zamień komendy
|
||||
`/print` własnymi komendami:
|
||||
|
||||
----
|
||||
/key bind meta2-I /print -core focus
|
||||
@@ -469,9 +462,8 @@ key[shift]).
|
||||
[[irc_ssl_connection]]
|
||||
=== Mam problemy podczas połączenia z serwerem używającym SSL, co mogę zrobić?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
If you are using Mac OS X, you must install `curl-ca-bundle` and set the path
|
||||
to certificates in WeeChat:
|
||||
Jeśli używasz Mac OS X, musisz zainstalować `curl-ca-bundle` i ustawić ścieżkę
|
||||
do certyfikatów w WeeChat:
|
||||
|
||||
----
|
||||
/set weechat.network.gnutls_ca_file "/usr/local/opt/curl-ca-bundle/share/ca-bundle.crt"
|
||||
@@ -529,7 +521,7 @@ Niektóre serwery jak 'twitch' wymagają oauth do połączenia.
|
||||
|
||||
Oauth to po prostu hasło w postaci "oauth:hasło".
|
||||
|
||||
W celu dodania takiego serwera i połączenia się z nim należ wykonać nastepujące
|
||||
W celu dodania takiego serwera i połączenia się z nim należ wykonać następujące
|
||||
polecenia (należy zastąpić nazwę i adres odpowiednimi wartościami):
|
||||
|
||||
----
|
||||
@@ -595,15 +587,13 @@ Więcej informacji: `/help filter` i `/help irc.look.smart_filter`
|
||||
[[filter_irc_join_channel_messages]]
|
||||
=== Jak mogę filtrować wyświetlane wiadomości podczas wejścia na kanał IRC?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
With WeeChat ≥ 0.4.1, you can choose which messages are displayed or not when
|
||||
joining a channel with the option 'irc.look.display_join_message' (see
|
||||
`/help irc.look.display_join_message` for more info).
|
||||
W wersjach WeeChat ≥ 0.4.1, możesz wybrać to, jakie wiadomości są wyświetlane
|
||||
a jakie nie podczas wchodzenia na kanał, za pomocą opcji 'irc.look.display_join_message'
|
||||
(więcej informacji można znaleźć wykonując `/help irc.look.display_join_message`).
|
||||
|
||||
// TRANSLATION MISSING
|
||||
To hide messages (but keep them in buffer), you can filter them using the tag
|
||||
(for example 'irc_329' for channel creation date). See `/help filter` for help
|
||||
with filters.
|
||||
W celu ukrycia wiadomości (ale zachowując je w buforze), możesz je filtrować
|
||||
używając tagu (na przykład 'irc_329' dla daty utworzenia kanału). zobacz
|
||||
`/help filter` w celu uzyskania pomocy z filtrami.
|
||||
|
||||
[[filter_voice_messages]]
|
||||
=== Jak mogę filtrować informacje o przyznaniu voice (np na serwerze Bitlbee)?
|
||||
@@ -695,13 +685,11 @@ Musisz ustawić:
|
||||
/plugin autoload
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[[install_scripts]]
|
||||
=== How can I install scripts? Are scripts compatible with other IRC clients?
|
||||
=== Jak mogę instalować skrypty? Czy są one kompatybilne z innymi klientami IRC?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
You can use the command `/script` to install and manage scripts
|
||||
(see `/help script` for help).
|
||||
Możesz użyć komendy `/script` do instalowania i zarządzania skryptami
|
||||
(zobacz `/help script` po więcej informacji).
|
||||
|
||||
Skrypty nie są kompatybilne z innymi klientami IRC.
|
||||
|
||||
@@ -724,18 +712,16 @@ W celu zmniejszenia używanej pamięci możesz zastosować się do poniższych r
|
||||
wartość opcji 'weechat.history.max_buffer_lines_minutes'
|
||||
* zmniejszyć wartość opcji 'weechat.history.max_commands'
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[[cpu_usage]]
|
||||
=== How can I tweak WeeChat to use less CPU?
|
||||
=== Jak mogę zmusić WeeChat do zużywania mniejszej mocy CPU?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
You can follow same tips as for <<memory_usage,memory>>, and these ones:
|
||||
Możesz skorzystać z tych samych porad jak dla <<memory_usage,memory>>, oraz tych:
|
||||
|
||||
* hide "nicklist" bar: `/bar hide nicklist`
|
||||
* remove display of seconds in status bar time:
|
||||
`/set weechat.look.item_time_format "%H:%M"` (this is the default value)
|
||||
* set the 'TZ' variable (for example: `export TZ="Europe/Paris"`), to prevent
|
||||
frequent access to file '/etc/localtime'
|
||||
* schowaj pasek "nicklist": `/bar hide nicklist`
|
||||
* usuń wyświetlanie sekund w czasie na pasku statusu:
|
||||
`/set weechat.look.item_time_format "%H:%M"` (domyślna wartość)
|
||||
* ustaw zmienną 'TZ' (na przykład: `export TZ="Europe/Warsaw"`), w celu zmniejszenia
|
||||
częstotliwości czytania pliku '/etc/localtime'
|
||||
|
||||
[[development]]
|
||||
== Rozwój
|
||||
@@ -743,8 +729,7 @@ You can follow same tips as for <<memory_usage,memory>>, and these ones:
|
||||
[[bug_task_patch]]
|
||||
=== Jak zgłaszać błędy, prosić o nowe możliwości lub wysyłać patche?
|
||||
|
||||
// TRANSLATION MISSING
|
||||
See: http://weechat.org/dev/support
|
||||
Zobacz: http://weechat.org/dev/support
|
||||
|
||||
[[gdb_error_threads]]
|
||||
=== Kiedy uruchamiam WeeChat pod gdb dostaję komunikat o wątkach, co mogę z tym zrobić?
|
||||
|
||||
@@ -94,11 +94,9 @@ na liście "irc" oraz inne wtyczki.
|
||||
[[create_irc_server]]
|
||||
== Tworzenie serwera IRC
|
||||
|
||||
// TRANSLATION MISSING
|
||||
The server 'freenode' is created by default on first startup.
|
||||
Serwer 'freenode' jest tworzony domyślnie przy pierwszym uruchomieniu.
|
||||
|
||||
// TRANSLATION MISSING
|
||||
You can add another IRC server with `/server` command, for example:
|
||||
Możesz dodać inne serwery IRC za pomocą komendy '/server', na przykład:
|
||||
|
||||
----
|
||||
/server add oftc irc.oftc.net/6667
|
||||
@@ -140,8 +138,7 @@ Aby włączyć automatyczne łączenie się z serwerem przy starcie:
|
||||
/set irc.server.freenode.autoconnect on
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
To connect with SSL:
|
||||
W celu połączenia z użyciem SSL:
|
||||
|
||||
----
|
||||
/set irc.server.freenode.addresses "chat.freenode.net/7000"
|
||||
@@ -149,10 +146,9 @@ To connect with SSL:
|
||||
/set irc.server.freenode.ssl_dhkey_size 1024
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[NOTE]
|
||||
Freenode does not support the default dhkey size of 2048, so it has to be set
|
||||
to 1024.
|
||||
Freenode nie wspiera domyślnego rozmiaru klucza dhkey 2048, dlatego należy go
|
||||
ustawić na 1024.
|
||||
|
||||
Jeśli SASL jest dostępny na serwerze, można użyć go do uwierzytelnienia (zostaniesz
|
||||
zidentyfikowany przed wejściem na kanał):
|
||||
@@ -170,9 +166,8 @@ przez nickserv (tylko jeśli nie uwierzytelniasz się przez SASL):
|
||||
/set irc.server.freenode.command "/msg nickserv identify xxxxxxx"
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[NOTE]
|
||||
Many commands in option 'command' can be separated by ';' (semi-colon).
|
||||
Opcja 'command' może zawierać wiele komend, należy je oddzielić ';' (średnik).
|
||||
|
||||
Aby automatycznie wejść na kanały po połączeniu z serwerem:
|
||||
|
||||
@@ -202,12 +197,12 @@ nazwa opcji):
|
||||
----
|
||||
|
||||
[NOTE]
|
||||
Ta komenda może być użyta do utworzenia i połączenia sie z nowym serwerem bez
|
||||
Ta komenda może być użyta do utworzenia i połączenia się z nowym serwerem bez
|
||||
użycia komendy `/server` (czy mam powtarzać, że pomoc dla tej komendy można
|
||||
uzyskać dzięki `/help connect` ?).
|
||||
|
||||
Domyślnie bufory serwerów są połączone z buforem WeeChat 'core'. Aby przełączać
|
||||
się pomiędzy biforem 'core' a buforami serwerów możesz użyć key[ctrl-x].
|
||||
się pomiędzy buforem 'core' a buforami serwerów możesz użyć key[ctrl-x].
|
||||
|
||||
Jest możliwe wyłączenie automatycznego łączenia buforów serwerów, aby mieć
|
||||
oddzielne bufory dla serwerów:
|
||||
@@ -237,17 +232,16 @@ Zamknięcie bufora serwera lub kanału (`/close` jest aliasem `/buffer close`):
|
||||
/close
|
||||
----
|
||||
|
||||
// TRANSLATION MISSING
|
||||
[[irc_private_messages]]
|
||||
== IRC private messages
|
||||
== Prywatne wiadomości IRC
|
||||
|
||||
Open a buffer and send a message to another user (nick 'foo'):
|
||||
Otworzenie bufora i wysłanie wiadomości do innego użytkownika (nick 'foo'):
|
||||
|
||||
----
|
||||
/query foo this is a message
|
||||
/query foo to jest wiadomość
|
||||
----
|
||||
|
||||
Close the private buffer:
|
||||
Zamykanie prywatnego bufora:
|
||||
|
||||
----
|
||||
/close
|
||||
|
||||
+294
-311
File diff suppressed because it is too large
Load Diff
@@ -20,8 +20,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:49+0200\n"
|
||||
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: cs\n"
|
||||
@@ -3903,20 +3903,28 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "bajtů"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "bajt"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "bajt"
|
||||
msgstr[1] "bajt"
|
||||
msgstr[2] "bajt"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -7596,8 +7604,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s zrušil téma pro %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallops od %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallops od %s: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -9050,7 +9058,7 @@ msgstr "Klienti pro přenos:"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" id: %d, %s%s%s (%s%s%s), spuštěn v: %s, poslední aktivita: %s, bytů: %lu "
|
||||
|
||||
@@ -22,8 +22,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 19:29+0100\n"
|
||||
"POT-Creation-Date: 2014-07-25 20:37+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 09:12+0100\n"
|
||||
"Last-Translator: Nils Görs <weechatter@arcor.de>\n"
|
||||
"Language-Team: German <weechatter@arcor.de>\n"
|
||||
"Language: de_DE\n"
|
||||
@@ -939,9 +939,9 @@ msgstr ""
|
||||
"%sUpgrade nicht möglich: WeeChat Binärcode \"%s\" besitzt nicht die "
|
||||
"notwendigen Rechte"
|
||||
|
||||
#, fuzzy, c-format
|
||||
#, c-format
|
||||
msgid "%sNo binary specified"
|
||||
msgstr "Keine Infobar definiert"
|
||||
msgstr "%skeine Binärdatei angegeben"
|
||||
|
||||
#, c-format
|
||||
msgid "Upgrading WeeChat with binary file: \"%s\"..."
|
||||
@@ -4577,20 +4577,26 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr "keine schutzwürdigen Daten definiert"
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "Bytes"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr "TB"
|
||||
|
||||
msgid "byte"
|
||||
msgstr "Byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "Byte"
|
||||
msgstr[1] "Bytes"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -4704,28 +4710,28 @@ msgid ""
|
||||
"Warning: the %d color pairs are used, do \"/color reset\" to remove unused "
|
||||
"pairs"
|
||||
msgstr ""
|
||||
"Warnung: die Farbpaarung %d wird bereits genutzt. Nutze \"/color reset\" um "
|
||||
"ungenutzte Farbpaarungen zu entfernen"
|
||||
"Warnung: die Farbpaarung %d wird bereits verwendet. Nutze \"/color reset\" "
|
||||
"um ungenutzte Farbpaarungen zu entfernen"
|
||||
|
||||
msgid "Terminal infos:"
|
||||
msgstr "Terminal Informationen:"
|
||||
msgstr "Informationen zum Terminal:"
|
||||
|
||||
msgid "No color support in terminal."
|
||||
msgstr "Keine Unterstützung von Farben im Terminal."
|
||||
msgstr "keine Farbunterstützung durch Terminal."
|
||||
|
||||
msgid "Default colors:"
|
||||
msgstr "Standardfarben:"
|
||||
|
||||
msgid "Terminal colors:"
|
||||
msgstr "Terminal-Farben:"
|
||||
msgstr "Terminalfarben:"
|
||||
|
||||
msgid ""
|
||||
"WeeChat colors | Actions: [e] Display extra infos [r] Refresh [z] Reset "
|
||||
"colors [q] Close buffer | Keys: [alt-c] Temporarily switch to terminal colors"
|
||||
msgstr ""
|
||||
"WeeChat Farben | Aktionen: [e] Zeigt zusätzliche Informationen an [r] "
|
||||
"WeeChat Farben | Aktionen: [e] zeigt zusätzliche Informationen an [r] "
|
||||
"aktualisieren [z] Farben zurücksetzen [q] Buffer schließen | Befehle: [alt-"
|
||||
"c] wechselt Farben (für 10 Sekunden)"
|
||||
"c] wechsel zu Terminalfarben (für 10 Sekunden)"
|
||||
|
||||
#, c-format
|
||||
msgid "WeeChat color pairs auto-allocated (in use: %d, left: %d):"
|
||||
@@ -4762,10 +4768,10 @@ msgid "Terminal lost, exiting WeeChat..."
|
||||
msgstr "Terminal verloren, beende WeeChat..."
|
||||
|
||||
msgid "Mouse is enabled"
|
||||
msgstr "Maus ist aktiviert"
|
||||
msgstr "Maus ist aktiv"
|
||||
|
||||
msgid "Mouse is disabled"
|
||||
msgstr "Maus ist deaktiviert"
|
||||
msgstr "Maus ist inaktiv"
|
||||
|
||||
#, c-format
|
||||
msgid " TERM='%s', size: %dx%d"
|
||||
@@ -4776,13 +4782,13 @@ msgid ""
|
||||
"%sUnable to change bar type: you must delete bar and create another to do "
|
||||
"that"
|
||||
msgstr ""
|
||||
"%sKann Bar-Typ nicht ändern: Es muss zuerst die Bar gelöscht und danach neu "
|
||||
"%sBar-Typ kann nicht verändert werden: die Bar muss gelöscht und danach neu "
|
||||
"erstellt werden"
|
||||
|
||||
msgid "true if bar is hidden, false if it is displayed"
|
||||
msgstr ""
|
||||
"Einschalten, falls Bar versteckt werden soll. Ausschalten, falls Bar "
|
||||
"angezeigt werden soll"
|
||||
"wahr, falls Bar versteckt werden soll. unwahr, falls Bar angezeigt werden "
|
||||
"soll"
|
||||
|
||||
msgid "bar priority (high number means bar displayed first)"
|
||||
msgstr ""
|
||||
@@ -4960,7 +4966,7 @@ msgstr "Alias \"%s\" => \"%s\" angelegt"
|
||||
|
||||
#, c-format
|
||||
msgid "No alias found matching \"%s\""
|
||||
msgstr "Keinen passenden Alias zu \"%s\" gefunden"
|
||||
msgstr "keinen passenden Alias zu \"%s\" gefunden"
|
||||
|
||||
#, c-format
|
||||
msgid "%sAlias \"%s\" not found"
|
||||
@@ -5045,7 +5051,7 @@ msgstr ""
|
||||
" /alias -completion %%sajoin forcejoin /quote forcejoin"
|
||||
|
||||
msgid "remove aliases"
|
||||
msgstr "Entferne Alias"
|
||||
msgstr "entferne Alias"
|
||||
|
||||
msgid "<alias> [<alias>...]"
|
||||
msgstr "<alias> [<alias>...]"
|
||||
@@ -5100,7 +5106,7 @@ msgid ""
|
||||
"dictionary"
|
||||
msgstr ""
|
||||
"%s%s: es sind mehrere Wörterbücher für diesen Buffer definiert. Bitte wählen "
|
||||
"Sie ein Wörterbuch davon aus"
|
||||
"Sie ein Wörterbuch aus"
|
||||
|
||||
#, c-format
|
||||
msgid "%s: word \"%s\" added to personal dictionary"
|
||||
@@ -8685,8 +8691,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s hat das Thema von %s%s%s entfernt"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallops von %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallops von %s: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -10134,11 +10140,11 @@ msgstr "Verbindungen zu Clients für Relay:"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s), gestartet am: %s, letzte Aktivität: %s, Bytes: %lu "
|
||||
"empfangen, %lu gesendet"
|
||||
" %s%s%s (%s%s%s), gestartet am: %s, letzte Aktivität: %s, Bytes: %llu "
|
||||
"empfangen, %llu gesendet"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
@@ -22,8 +22,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-07-25 20:37+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:49+0200\n"
|
||||
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: es\n"
|
||||
@@ -4114,20 +4114,27 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "bytes"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "byte"
|
||||
msgstr[1] "byte"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -7886,8 +7893,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s ha borrado el tema para %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallops de %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallops de %s: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -9330,11 +9337,11 @@ msgstr "Clientes conectados para retransmitir:"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s), iniciado en: %s, última actividad: %s, bytes: %lu "
|
||||
"recibidos, %lu enviados"
|
||||
" %s%s%s (%s%s%s), iniciado en: %s, última actividad: %s, bytes: %llu "
|
||||
"recibidos, %llu enviados"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
@@ -21,8 +21,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-20 12:27+0200\n"
|
||||
"POT-Creation-Date: 2014-07-25 20:37+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:49+0200\n"
|
||||
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: fr\n"
|
||||
@@ -4478,20 +4478,26 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr "Pas de donnée sécurisée définie"
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "octets"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "Ko"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "Mo"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "Go"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr "To"
|
||||
|
||||
msgid "byte"
|
||||
msgstr "octet"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "octet"
|
||||
msgstr[1] "octets"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -8471,8 +8477,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s a retiré le titre pour %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallops de %s%s %s(%s%s%s)%s : %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallops de %s : %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -9908,11 +9914,11 @@ msgstr "Clients connectés pour le relai :"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s), démarré le : %s, dernière activité : %s, octets : %lu "
|
||||
"reçus, %lu envoyés"
|
||||
" %s%s%s (%s%s%s), démarré le : %s, dernière activité : %s, octets : %llu "
|
||||
"reçus, %llu envoyés"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
@@ -20,8 +20,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:49+0200\n"
|
||||
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: hu\n"
|
||||
@@ -3525,21 +3525,27 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "byte"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "byte"
|
||||
msgstr[1] "byte"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -7057,7 +7063,7 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s törölte a %s%s szoba témáját\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%s%s %s(%s%s@%s%s)%s neve %s volt\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
@@ -8447,7 +8453,7 @@ msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -20,8 +20,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-07-25 20:37+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:49+0200\n"
|
||||
"Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: it\n"
|
||||
@@ -4237,20 +4237,27 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr "Dati sicuri non configurati"
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "byte"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "byte"
|
||||
msgstr[1] "byte"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -8044,8 +8051,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s ha rimosso l'argomento per %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallop da %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallop da %s: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -9487,11 +9494,11 @@ msgstr "Client connessi per il relay:"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s), avviato il %s, attività recente: %s byte: %lu ricevuti, "
|
||||
"%lu inviati"
|
||||
" %s%s%s (%s%s%s), avviato il %s, attività recente: %s byte: %llu ricevuti, "
|
||||
"%llu inviati"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
@@ -20,8 +20,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 11:25+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:50+0200\n"
|
||||
"Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n"
|
||||
"Language-Team: Japanese <https://github.com/l/weechat/tree/translation_ja>\n"
|
||||
"Language: ja\n"
|
||||
@@ -183,10 +183,13 @@ msgid ""
|
||||
"%sWarning: WeeChat is running under %s and $TERM is \"%s\", which can cause "
|
||||
"display bugs; $TERM should be set to \"screen-256color\" or \"screen\""
|
||||
msgstr ""
|
||||
"%s警告: WeeChat は %s の中で実行中で $TERM は \"%s\" です、この状態は表示上の"
|
||||
"バグを引き起こす恐れがあります; $TERM を \"screen-256color\" または \"screen"
|
||||
"\" に設定してください"
|
||||
|
||||
#, c-format
|
||||
msgid "%sYou should add this line in the file %s: %s"
|
||||
msgstr ""
|
||||
msgstr "%sファイル %s にこの行を追加してください: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "Signal %s received, exiting WeeChat..."
|
||||
@@ -909,9 +912,9 @@ msgid ""
|
||||
msgstr ""
|
||||
"%sアップグレードできません: WeeChat バイナリ \"%s\" の実行許可がありません"
|
||||
|
||||
#, fuzzy, c-format
|
||||
#, c-format
|
||||
msgid "%sNo binary specified"
|
||||
msgstr "バーが定義されていません"
|
||||
msgstr "%sバイナリが指定されていません"
|
||||
|
||||
#, c-format
|
||||
msgid "Upgrading WeeChat with binary file: \"%s\"..."
|
||||
@@ -2506,9 +2509,8 @@ msgid "unset/reset config options"
|
||||
msgstr "オプションのアンセット/リセット"
|
||||
|
||||
msgid "<option> || -mask <option>"
|
||||
msgstr ""
|
||||
msgstr "<option> || -mask <option>"
|
||||
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
"option: name of an option\n"
|
||||
" -mask: use a mask in option (wildcard \"*\" is allowed to mass-reset "
|
||||
@@ -2523,8 +2525,9 @@ msgid ""
|
||||
" reset all color options:\n"
|
||||
" /unset -mask weechat.color.*"
|
||||
msgstr ""
|
||||
"option: オプションの名前 (大量のオプションをリセットするにはワイルドカード "
|
||||
"\"*\" を使ってください、注意して使用!)\n"
|
||||
"option: オプションの名前\n"
|
||||
" -mask: オプション内でマスクを使う (大量のオプションをリセットするにはワイル"
|
||||
"ドカード \"*\" を使ってください、使用に注意!)\n"
|
||||
"\n"
|
||||
"オプションの種類によって (一般的なオプションを) リセットまたは (サーバなどの"
|
||||
"任意な設定を) 削除が行われます。\n"
|
||||
@@ -2533,7 +2536,7 @@ msgstr ""
|
||||
" オプションのリセット:\n"
|
||||
" /unset weechat.look.item_time_format\n"
|
||||
" 全ての色関連オプションをリセット:\n"
|
||||
" /unset weechat.color.*"
|
||||
" /unset -mask weechat.color.*"
|
||||
|
||||
msgid "upgrade WeeChat without disconnecting from servers"
|
||||
msgstr "サーバとの接続を維持して WeeChat をアップグレード"
|
||||
@@ -3859,9 +3862,8 @@ msgstr ""
|
||||
"SSL などでセキュリティプロトコルを使っている場合のステータスバーの現在のバッ"
|
||||
"ファ名のテキスト色、"
|
||||
|
||||
#, fuzzy
|
||||
msgid "text color for number of nicks in nicklist (status bar)"
|
||||
msgstr "ホットリスト内のメッセージ数のテキスト色 (ステータスバー)"
|
||||
msgstr "ニックネームリスト内のニックネーム数のテキスト色 (ステータスバー)"
|
||||
|
||||
msgid "text color for current buffer number in status bar"
|
||||
msgstr "ステータスバーの現在のバッファ番号のテキスト色"
|
||||
@@ -4289,20 +4291,25 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr "保護データが設定されていません"
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "バイト"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "キロバイト"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "メガバイト"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "ギガバイト"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr "テラバイト"
|
||||
|
||||
msgid "byte"
|
||||
msgstr "バイト"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "バイト"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -8135,8 +8142,8 @@ msgstr "%s%s%s%s が %s%s%s のトピックを削除 (古いトピック: \"%s%s
|
||||
msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s が %s%s%s のトピックを削除"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
#, fuzzy, c-format
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sから %s%s Wallops 権を取得 %s(%s%s%s)%s: %s"
|
||||
|
||||
#, c-format
|
||||
@@ -9534,10 +9541,10 @@ msgstr "リレーする接続済みクライアント:"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s)、開始日時: %s、最新の活動: %s、バイト数: %lu 受信、%lu 送信"
|
||||
" %s%s%s (%s%s%s)、開始日時: %s、最新の活動: %s、バイト数: %llu 受信、%llu 送信"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
@@ -21,8 +21,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-07-25 20:37+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:50+0200\n"
|
||||
"Last-Translator: Krzysztof Korościk <soltys@szluug.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: pl\n"
|
||||
@@ -4359,20 +4359,28 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr "Brak zabezpieczonych danych"
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "bajty"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "bajt"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "bajt"
|
||||
msgstr[1] "bajt"
|
||||
msgstr[2] "bajt"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -8231,8 +8239,8 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s usunął temat %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgstr "%sWallopy od %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%sWallopy od %s: %s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sUser mode for %s%s%s is %s[%s%s%s]"
|
||||
@@ -9652,11 +9660,11 @@ msgstr "Klienci do przekazywania:"
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" %s%s%s (%s%s%s), rozpoczęto: %s, ostatnia aktywność: %s, bajtów: %lu "
|
||||
"odebrano, %lu wysłano"
|
||||
" %s%s%s (%s%s%s), rozpoczęto: %s, ostatnia aktywność: %s, bajtów: %llu "
|
||||
"odebrano, %llu wysłano"
|
||||
|
||||
#, c-format
|
||||
msgid " %s%s%s (%s%s%s), started on: %s"
|
||||
|
||||
+13
-7
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"Last-Translator: Sergio Durigan Junior <sergiosdj@gmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -4005,21 +4005,27 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr ""
|
||||
|
||||
msgid "byte"
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
msgid "byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] ""
|
||||
msgstr[1] ""
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
msgstr ""
|
||||
@@ -7306,7 +7312,7 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s%s limpou o tópico do canal %s%s%s"
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
@@ -8710,7 +8716,7 @@ msgstr "Clientes para relay:"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
" id: %d, %s%s%s (%s%s%s), iniciado em: %s, última atividade: %s, %lu bytes "
|
||||
|
||||
@@ -21,8 +21,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:50+0200\n"
|
||||
"Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: ru\n"
|
||||
@@ -3554,21 +3554,28 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "байтов"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "КБ"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "МБ"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "ГБ"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "байтов"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "байтов"
|
||||
msgstr[1] "байтов"
|
||||
msgstr[2] "байтов"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -7084,7 +7091,7 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr "%s%s%s удалил тему канала для %s%s\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr "%s%s %s(%s%s@%s%s)%s был %s\n"
|
||||
|
||||
#, fuzzy, c-format
|
||||
@@ -8474,7 +8481,7 @@ msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -20,8 +20,8 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"PO-Revision-Date: 2014-07-14 18:44+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2014-07-25 07:50+0200\n"
|
||||
"Last-Translator: Hasan Kiran <sunder67@hotmail.com>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
"Language: tr\n"
|
||||
@@ -3167,20 +3167,26 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr "bayt"
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr "KB"
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr "MB"
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr "GB"
|
||||
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
#, fuzzy
|
||||
msgid "byte"
|
||||
msgstr "bayt"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] "bayt"
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
@@ -6320,7 +6326,7 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
@@ -7594,7 +7600,7 @@ msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
|
||||
|
||||
+13
-7
@@ -21,7 +21,7 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: WeeChat 0.4.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
|
||||
"POT-Creation-Date: 2014-07-20 12:16+0200\n"
|
||||
"POT-Creation-Date: 2014-08-02 16:12+0200\n"
|
||||
"PO-Revision-Date: 2013-02-14 18:20+0100\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
|
||||
@@ -3166,21 +3166,27 @@ msgstr ""
|
||||
msgid "No secured data set"
|
||||
msgstr ""
|
||||
|
||||
msgid "bytes"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "kilobyte"
|
||||
msgid "KB"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "megabyte"
|
||||
msgid "MB"
|
||||
msgstr ""
|
||||
|
||||
#. TRANSLATORS: file size unit "gigabyte"
|
||||
msgid "GB"
|
||||
msgstr ""
|
||||
|
||||
msgid "byte"
|
||||
#. TRANSLATORS: file size unit "terabyte"
|
||||
msgid "TB"
|
||||
msgstr ""
|
||||
|
||||
msgid "byte"
|
||||
msgid_plural "bytes"
|
||||
msgstr[0] ""
|
||||
msgstr[1] ""
|
||||
|
||||
#, c-format
|
||||
msgid "debug: removing file: %s"
|
||||
msgstr ""
|
||||
@@ -6259,7 +6265,7 @@ msgid "%s%s%s%s has unset topic for %s%s%s"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid "%sWallops from %s%s %s(%s%s%s)%s: %s"
|
||||
msgid "%sWallops from %s: %s"
|
||||
msgstr ""
|
||||
|
||||
#, c-format
|
||||
@@ -7537,7 +7543,7 @@ msgstr ""
|
||||
|
||||
#, c-format
|
||||
msgid ""
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %lu recv, %lu "
|
||||
" %s%s%s (%s%s%s), started on: %s, last activity: %s, bytes: %llu recv, %llu "
|
||||
"sent"
|
||||
msgstr ""
|
||||
|
||||
|
||||
+6
-4
@@ -52,15 +52,17 @@ run "cd $BUILDDIR"
|
||||
|
||||
if [ "$BUILDTOOL" = "cmake" ]; then
|
||||
# build with CMake
|
||||
run "cmake .. -DENABLE_MAN=ON -DENABLE_DOC=ON"
|
||||
run "make VERBOSE=1"
|
||||
run "cmake .. -DENABLE_MAN=ON -DENABLE_DOC=ON -DENABLE_TESTS=ON"
|
||||
run "make VERBOSE=1 -j$(nproc)"
|
||||
run "sudo make install"
|
||||
run "ctest -V"
|
||||
fi
|
||||
|
||||
if [ "$BUILDTOOL" = "autotools" ]; then
|
||||
# build with autotools
|
||||
run "../autogen.sh"
|
||||
run "../configure --enable-man --enable-doc"
|
||||
run "make"
|
||||
run "../configure --enable-man --enable-doc --enable-tests"
|
||||
run "make -j$(nproc)"
|
||||
run "sudo make install"
|
||||
run "./tests/tests -v"
|
||||
fi
|
||||
|
||||
@@ -606,7 +606,7 @@ COMMAND_CALLBACK(buffer)
|
||||
else
|
||||
{
|
||||
ptr_buffer = gui_buffer_search_by_number_or_name (argv[i]);
|
||||
number = strtol (argv[2], &error, 10);
|
||||
(void) strtol (argv[i], &error, 10);
|
||||
clear_number = (error && !error[0]);
|
||||
}
|
||||
if (ptr_buffer)
|
||||
@@ -784,7 +784,7 @@ COMMAND_CALLBACK(buffer)
|
||||
ptr_buffer = gui_buffer_search_by_number_or_name (argv[i]);
|
||||
if (ptr_buffer)
|
||||
{
|
||||
number = strtol (argv[2], &error, 10);
|
||||
(void) strtol (argv[i], &error, 10);
|
||||
if (error && !error[0])
|
||||
{
|
||||
for (ptr_buffer2 = gui_buffers; ptr_buffer2;
|
||||
@@ -822,7 +822,7 @@ COMMAND_CALLBACK(buffer)
|
||||
ptr_buffer = gui_buffer_search_by_number_or_name (argv[i]);
|
||||
if (ptr_buffer)
|
||||
{
|
||||
number = strtol (argv[2], &error, 10);
|
||||
(void) strtol (argv[i], &error, 10);
|
||||
if (error && !error[0])
|
||||
{
|
||||
for (ptr_buffer2 = gui_buffers; ptr_buffer2;
|
||||
|
||||
+209
-206
@@ -910,231 +910,234 @@ completion_list_add_config_option_values_cb (void *data,
|
||||
(void) completion_item;
|
||||
(void) buffer;
|
||||
|
||||
if (completion->args)
|
||||
if (!completion->args)
|
||||
return WEECHAT_RC_OK;
|
||||
|
||||
pos_space = strchr (completion->args, ' ');
|
||||
if (pos_space)
|
||||
option_full_name = string_strndup (completion->args,
|
||||
pos_space - completion->args);
|
||||
else
|
||||
option_full_name = strdup (completion->args);
|
||||
|
||||
if (!option_full_name)
|
||||
return WEECHAT_RC_OK;
|
||||
|
||||
file = NULL;
|
||||
section = NULL;
|
||||
pos_option = NULL;
|
||||
|
||||
pos_section = strchr (option_full_name, '.');
|
||||
pos_option = (pos_section) ? strchr (pos_section + 1, '.') : NULL;
|
||||
|
||||
if (pos_section && pos_option)
|
||||
{
|
||||
pos_space = strchr (completion->args, ' ');
|
||||
if (pos_space)
|
||||
option_full_name = string_strndup (completion->args,
|
||||
pos_space - completion->args);
|
||||
else
|
||||
option_full_name = strdup (completion->args);
|
||||
|
||||
if (option_full_name)
|
||||
file = string_strndup (option_full_name,
|
||||
pos_section - option_full_name);
|
||||
section = string_strndup (pos_section + 1,
|
||||
pos_option - pos_section - 1);
|
||||
pos_option++;
|
||||
}
|
||||
if (file && section && pos_option)
|
||||
{
|
||||
ptr_config = config_file_search (file);
|
||||
if (ptr_config)
|
||||
{
|
||||
file = NULL;
|
||||
section = NULL;
|
||||
pos_option = NULL;
|
||||
|
||||
pos_section = strchr (option_full_name, '.');
|
||||
pos_option = (pos_section) ? strchr (pos_section + 1, '.') : NULL;
|
||||
|
||||
if (pos_section && pos_option)
|
||||
ptr_section = config_file_search_section (ptr_config,
|
||||
section);
|
||||
if (ptr_section)
|
||||
{
|
||||
file = string_strndup (option_full_name,
|
||||
pos_section - option_full_name);
|
||||
section = string_strndup (pos_section + 1,
|
||||
pos_option - pos_section - 1);
|
||||
pos_option++;
|
||||
}
|
||||
if (file && section && pos_option)
|
||||
{
|
||||
ptr_config = config_file_search (file);
|
||||
if (ptr_config)
|
||||
config_file_search_section_option (ptr_config,
|
||||
ptr_section,
|
||||
pos_option,
|
||||
§ion_found,
|
||||
&option_found);
|
||||
if (option_found)
|
||||
{
|
||||
ptr_section = config_file_search_section (ptr_config,
|
||||
section);
|
||||
if (ptr_section)
|
||||
switch (option_found->type)
|
||||
{
|
||||
config_file_search_section_option (ptr_config,
|
||||
ptr_section,
|
||||
pos_option,
|
||||
§ion_found,
|
||||
&option_found);
|
||||
if (option_found)
|
||||
{
|
||||
switch (option_found->type)
|
||||
case CONFIG_OPTION_TYPE_BOOLEAN:
|
||||
gui_completion_list_add (completion, "on",
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
gui_completion_list_add (completion, "off",
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
gui_completion_list_add (completion, "toggle",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
case CONFIG_OPTION_TYPE_BOOLEAN:
|
||||
if (CONFIG_BOOLEAN(option_found) == CONFIG_BOOLEAN_TRUE)
|
||||
gui_completion_list_add (completion, "on",
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
gui_completion_list_add (completion, "off",
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
gui_completion_list_add (completion, "toggle",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
if (CONFIG_BOOLEAN(option_found) == CONFIG_BOOLEAN_TRUE)
|
||||
gui_completion_list_add (completion, "on",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
else
|
||||
gui_completion_list_add (completion, "off",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_INTEGER:
|
||||
if (option_found->string_values)
|
||||
{
|
||||
for (i = 0; option_found->string_values[i]; i++)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
option_found->string_values[i],
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
}
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
option_found->string_values[CONFIG_INTEGER(option_found)],
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (option_found->value && CONFIG_INTEGER(option_found) > option_found->min)
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value && CONFIG_INTEGER(option_found) < option_found->max)
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value)
|
||||
{
|
||||
length = 64;
|
||||
value_string = malloc (length);
|
||||
if (value_string)
|
||||
{
|
||||
snprintf (value_string, length,
|
||||
"%d", CONFIG_INTEGER(option_found));
|
||||
gui_completion_list_add (completion,
|
||||
value_string,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
free (value_string);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_STRING:
|
||||
gui_completion_list_add (completion,
|
||||
"\"\"",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value)
|
||||
{
|
||||
length = strlen (CONFIG_STRING(option_found)) + 2 + 1;
|
||||
value_string = malloc (length);
|
||||
if (value_string)
|
||||
{
|
||||
snprintf (value_string, length,
|
||||
"\"%s\"",
|
||||
CONFIG_STRING(option_found));
|
||||
gui_completion_list_add (completion,
|
||||
value_string,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
free (value_string);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_COLOR:
|
||||
num_colors = gui_color_get_weechat_colors_number ();
|
||||
for (i = 0; i < num_colors; i++)
|
||||
{
|
||||
color_name = gui_color_get_name (i);
|
||||
if (color_name)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_name,
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
}
|
||||
}
|
||||
num_colors = gui_color_get_term_colors ();
|
||||
for (i = 0; i <= num_colors; i++)
|
||||
{
|
||||
color_palette = gui_color_palette_get (i);
|
||||
if (color_palette)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_palette->alias,
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
}
|
||||
else
|
||||
{
|
||||
snprintf (str_number,
|
||||
sizeof (str_number),
|
||||
"%d",
|
||||
i);
|
||||
gui_completion_list_add (completion,
|
||||
str_number,
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
}
|
||||
}
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
color_name = gui_color_get_name (CONFIG_INTEGER(option_found));
|
||||
if (color_name)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_name,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
break;
|
||||
case CONFIG_NUM_OPTION_TYPES:
|
||||
break;
|
||||
else
|
||||
gui_completion_list_add (completion, "off",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
if (option_found->value
|
||||
&& option_found->null_value_allowed)
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0,
|
||||
WEECHAT_LIST_POS_END);
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_INTEGER:
|
||||
if (option_found->string_values)
|
||||
{
|
||||
for (i = 0; option_found->string_values[i]; i++)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
option_found->string_values[i],
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
}
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
option_found->string_values[CONFIG_INTEGER(option_found)],
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (option_found->value && CONFIG_INTEGER(option_found) > option_found->min)
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value && CONFIG_INTEGER(option_found) < option_found->max)
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value)
|
||||
{
|
||||
length = 64;
|
||||
value_string = malloc (length);
|
||||
if (value_string)
|
||||
{
|
||||
snprintf (value_string, length,
|
||||
"%d", CONFIG_INTEGER(option_found));
|
||||
gui_completion_list_add (completion,
|
||||
value_string,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
free (value_string);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_STRING:
|
||||
gui_completion_list_add (completion,
|
||||
"\"\"",
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
if (option_found->value)
|
||||
{
|
||||
length = strlen (CONFIG_STRING(option_found)) + 2 + 1;
|
||||
value_string = malloc (length);
|
||||
if (value_string)
|
||||
{
|
||||
snprintf (value_string, length,
|
||||
"\"%s\"",
|
||||
CONFIG_STRING(option_found));
|
||||
gui_completion_list_add (completion,
|
||||
value_string,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
free (value_string);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
break;
|
||||
case CONFIG_OPTION_TYPE_COLOR:
|
||||
num_colors = gui_color_get_weechat_colors_number ();
|
||||
for (i = 0; i < num_colors; i++)
|
||||
{
|
||||
color_name = gui_color_get_name (i);
|
||||
if (color_name)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_name,
|
||||
0, WEECHAT_LIST_POS_SORT);
|
||||
}
|
||||
}
|
||||
num_colors = gui_color_get_term_colors ();
|
||||
for (i = 0; i <= num_colors; i++)
|
||||
{
|
||||
color_palette = gui_color_palette_get (i);
|
||||
if (color_palette)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_palette->alias,
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
}
|
||||
else
|
||||
{
|
||||
snprintf (str_number,
|
||||
sizeof (str_number),
|
||||
"%d",
|
||||
i);
|
||||
gui_completion_list_add (completion,
|
||||
str_number,
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
}
|
||||
}
|
||||
gui_completion_list_add (completion, "++1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
gui_completion_list_add (completion, "--1",
|
||||
0, WEECHAT_LIST_POS_END);
|
||||
if (option_found->value)
|
||||
{
|
||||
color_name = gui_color_get_name (CONFIG_INTEGER(option_found));
|
||||
if (color_name)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
color_name,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0, WEECHAT_LIST_POS_BEGINNING);
|
||||
}
|
||||
break;
|
||||
case CONFIG_NUM_OPTION_TYPES:
|
||||
break;
|
||||
}
|
||||
if (option_found->value
|
||||
&& option_found->null_value_allowed)
|
||||
{
|
||||
gui_completion_list_add (completion,
|
||||
WEECHAT_CONFIG_OPTION_NULL,
|
||||
0,
|
||||
WEECHAT_LIST_POS_END);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (file)
|
||||
free (file);
|
||||
if (section)
|
||||
free (section);
|
||||
}
|
||||
}
|
||||
|
||||
if (file)
|
||||
free (file);
|
||||
if (section)
|
||||
free (section);
|
||||
|
||||
free (option_full_name);
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -979,6 +979,8 @@ config_file_option_reset (struct t_config_option *option, int run_callback)
|
||||
option->value = malloc (sizeof (int));
|
||||
if (option->value)
|
||||
CONFIG_INTEGER(option) = 0;
|
||||
else
|
||||
break;
|
||||
}
|
||||
if (CONFIG_INTEGER(option) == CONFIG_INTEGER_DEFAULT(option))
|
||||
rc = WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE;
|
||||
@@ -1009,6 +1011,8 @@ config_file_option_reset (struct t_config_option *option, int run_callback)
|
||||
option->value = malloc (sizeof (int));
|
||||
if (option->value)
|
||||
CONFIG_INTEGER(option) = 0;
|
||||
else
|
||||
break;
|
||||
}
|
||||
if (CONFIG_COLOR(option) == CONFIG_COLOR_DEFAULT(option))
|
||||
rc = WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE;
|
||||
|
||||
+13
-13
@@ -72,10 +72,10 @@ hashtable_get_type (const char *type)
|
||||
* Returns the hash of the string.
|
||||
*/
|
||||
|
||||
unsigned long
|
||||
unsigned long long
|
||||
hashtable_hash_key_djb2 (const char *string)
|
||||
{
|
||||
unsigned long hash;
|
||||
unsigned long long hash;
|
||||
const char *ptr_string;
|
||||
|
||||
hash = 5381;
|
||||
@@ -93,28 +93,28 @@ hashtable_hash_key_djb2 (const char *string)
|
||||
* Returns the hash of the key, depending on the type.
|
||||
*/
|
||||
|
||||
unsigned long
|
||||
unsigned long long
|
||||
hashtable_hash_key_default_cb (struct t_hashtable *hashtable, const void *key)
|
||||
{
|
||||
unsigned long hash;
|
||||
unsigned long long hash;
|
||||
|
||||
hash = 0;
|
||||
|
||||
switch (hashtable->type_keys)
|
||||
{
|
||||
case HASHTABLE_INTEGER:
|
||||
hash = (unsigned long)(*((int *)key));
|
||||
hash = (unsigned long long)(*((int *)key));
|
||||
break;
|
||||
case HASHTABLE_STRING:
|
||||
hash = hashtable_hash_key_djb2 ((const char *)key);
|
||||
break;
|
||||
case HASHTABLE_POINTER:
|
||||
hash = (unsigned long)((void *)key);
|
||||
hash = (unsigned long long)((unsigned long)((void *)key));
|
||||
break;
|
||||
case HASHTABLE_BUFFER:
|
||||
break;
|
||||
case HASHTABLE_TIME:
|
||||
hash = (unsigned long)(*((time_t *)key));
|
||||
hash = (unsigned long long)(*((time_t *)key));
|
||||
break;
|
||||
case HASHTABLE_NUM_TYPES:
|
||||
break;
|
||||
@@ -270,7 +270,7 @@ hashtable_alloc_type (enum t_hashtable_type type,
|
||||
*size = sizeof (void *);
|
||||
break;
|
||||
case HASHTABLE_BUFFER:
|
||||
if (value)
|
||||
if (value && (size_value > 0))
|
||||
{
|
||||
*pointer = malloc (size_value);
|
||||
if (*pointer)
|
||||
@@ -375,7 +375,7 @@ hashtable_set_with_size (struct t_hashtable *hashtable,
|
||||
const void *key, int key_size,
|
||||
const void *value, int value_size)
|
||||
{
|
||||
unsigned long hash;
|
||||
unsigned long long hash;
|
||||
struct t_hashtable_item *ptr_item, *pos_item, *new_item;
|
||||
|
||||
if (!hashtable || !key
|
||||
@@ -469,9 +469,9 @@ hashtable_set (struct t_hashtable *hashtable,
|
||||
|
||||
struct t_hashtable_item *
|
||||
hashtable_get_item (struct t_hashtable *hashtable, const void *key,
|
||||
unsigned long *hash)
|
||||
unsigned long long *hash)
|
||||
{
|
||||
unsigned long key_hash;
|
||||
unsigned long long key_hash;
|
||||
struct t_hashtable_item *ptr_item;
|
||||
|
||||
if (!hashtable || !key)
|
||||
@@ -1109,7 +1109,7 @@ hashtable_add_to_infolist (struct t_hashtable *hashtable,
|
||||
void
|
||||
hashtable_remove_item (struct t_hashtable *hashtable,
|
||||
struct t_hashtable_item *item,
|
||||
unsigned long hash)
|
||||
unsigned long long hash)
|
||||
{
|
||||
if (!hashtable || !item)
|
||||
return;
|
||||
@@ -1139,7 +1139,7 @@ void
|
||||
hashtable_remove (struct t_hashtable *hashtable, const void *key)
|
||||
{
|
||||
struct t_hashtable_item *ptr_item;
|
||||
unsigned long hash;
|
||||
unsigned long long hash;
|
||||
|
||||
if (!hashtable || !key)
|
||||
return;
|
||||
|
||||
@@ -23,8 +23,8 @@
|
||||
struct t_hashtable;
|
||||
struct t_infolist_item;
|
||||
|
||||
typedef unsigned long (t_hashtable_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key);
|
||||
typedef unsigned long long (t_hashtable_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key);
|
||||
typedef int (t_hashtable_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1, const void *key2);
|
||||
typedef void (t_hashtable_free_key)(struct t_hashtable *hashtable,
|
||||
@@ -40,7 +40,7 @@ typedef void (t_hashtable_map_string)(void *data,
|
||||
|
||||
/*
|
||||
* Hashtable is a structure with an array "htable", each entry is a pointer
|
||||
* to a linked list, and it is read with hashed key (as unsigned long).
|
||||
* to a linked list, and it is read with hashed key (as unsigned long long).
|
||||
* Keys with same hashed key are grouped in a linked list pointed by htable.
|
||||
* The htable is not sorted, the linked list is sorted.
|
||||
*
|
||||
@@ -112,7 +112,7 @@ struct t_hashtable
|
||||
/* never asked) */
|
||||
};
|
||||
|
||||
extern unsigned long hashtable_hash_key_djb2 (const char *string);
|
||||
extern unsigned long long hashtable_hash_key_djb2 (const char *string);
|
||||
extern struct t_hashtable *hashtable_new (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
@@ -128,7 +128,7 @@ extern struct t_hashtable_item *hashtable_set (struct t_hashtable *hashtable,
|
||||
const void *value);
|
||||
extern struct t_hashtable_item *hashtable_get_item (struct t_hashtable *hashtable,
|
||||
const void *key,
|
||||
unsigned long *hash);
|
||||
unsigned long long *hash);
|
||||
extern void *hashtable_get (struct t_hashtable *hashtable, const void *key);
|
||||
extern int hashtable_has_key (struct t_hashtable *hashtable, const void *key);
|
||||
extern void hashtable_map (struct t_hashtable *hashtable,
|
||||
|
||||
+5
-12
@@ -674,12 +674,9 @@ hook_command_exec (struct t_gui_buffer *buffer, int any_plugin,
|
||||
if (!buffer || !string || !string[0])
|
||||
return -1;
|
||||
|
||||
rc = hook_command_run_exec (buffer, string);
|
||||
if (rc == WEECHAT_RC_OK_EAT)
|
||||
if (hook_command_run_exec (buffer, string) == WEECHAT_RC_OK_EAT)
|
||||
return 1;
|
||||
|
||||
rc = -1;
|
||||
|
||||
argv = string_split (string, " ", 0, 0, &argc);
|
||||
if (argc == 0)
|
||||
{
|
||||
@@ -726,12 +723,9 @@ hook_command_exec (struct t_gui_buffer *buffer, int any_plugin,
|
||||
ptr_hook = next_hook;
|
||||
}
|
||||
|
||||
if (!hook_plugin && !hook_other_plugin)
|
||||
{
|
||||
/* command not found at all */
|
||||
rc = -1;
|
||||
}
|
||||
else
|
||||
rc = -1;
|
||||
|
||||
if (hook_plugin || hook_other_plugin)
|
||||
{
|
||||
if (!hook_plugin && (count_other_plugin > 1)
|
||||
&& (hook_other_plugin->priority == hook_other_plugin2->priority))
|
||||
@@ -1517,7 +1511,7 @@ hook_process_child (struct t_hook *hook_process)
|
||||
(void) f;
|
||||
}
|
||||
|
||||
rc = EXIT_SUCCESS;
|
||||
rc = EXIT_FAILURE;
|
||||
|
||||
if (strncmp (HOOK_PROCESS(hook_process, command), "url:", 4) == 0)
|
||||
{
|
||||
@@ -1605,7 +1599,6 @@ hook_process_child (struct t_hook *hook_process)
|
||||
string_free_split (exec_args);
|
||||
fprintf (stderr, "Error with command '%s'\n",
|
||||
HOOK_PROCESS(hook_process, command));
|
||||
rc = EXIT_FAILURE;
|
||||
}
|
||||
|
||||
fflush (stdout);
|
||||
|
||||
+69
-38
@@ -1354,12 +1354,12 @@ string_replace_regex_get_replace (const char *string, regmatch_t *regex_match,
|
||||
*
|
||||
* Examples:
|
||||
*
|
||||
* string | regex | replace | result
|
||||
* ----------+---------------+-----------+-------------
|
||||
* test foo | test | Z | Z foo
|
||||
* test foo | ^(test +)(.*) | $2 | foo
|
||||
* test foo | ^(test +)(.*) | $1 / $.*2 | test / ***
|
||||
* test foo | ^(test +)(.*) | $.%+ | %%%
|
||||
* string | regex | replace | result
|
||||
* ----------+---------------+----------+-------------
|
||||
* test foo | test | Z | Z foo
|
||||
* test foo | ^(test +)(.*) | $2 | foo
|
||||
* test foo | ^(test +)(.*) | $1/ $.*2 | test / ***
|
||||
* test foo | ^(test +)(.*) | $.%+ | %%%
|
||||
*
|
||||
* Note: result must be freed after use.
|
||||
*/
|
||||
@@ -1374,7 +1374,7 @@ string_replace_regex (const char *string, void *regex, const char *replace,
|
||||
int length, length_replace, start_offset, i, rc, end, last_match;
|
||||
regmatch_t regex_match[100];
|
||||
|
||||
if (!string)
|
||||
if (!string || !regex)
|
||||
return NULL;
|
||||
|
||||
length = strlen (string) + 1;
|
||||
@@ -2066,7 +2066,12 @@ string_iconv (int from_utf8, const char *from_code, const char *to_code,
|
||||
char *ptr_inbuf_shift;
|
||||
int done;
|
||||
size_t err, inbytesleft, outbytesleft;
|
||||
#endif
|
||||
|
||||
if (!string)
|
||||
return NULL;
|
||||
|
||||
#ifdef HAVE_ICONV
|
||||
if (from_code && from_code[0] && to_code && to_code[0]
|
||||
&& (string_strcasecmp(from_code, to_code) != 0))
|
||||
{
|
||||
@@ -2274,30 +2279,47 @@ string_iconv_fprintf (FILE *file, const char *data, ...)
|
||||
char *
|
||||
string_format_size (unsigned long long size)
|
||||
{
|
||||
char *unit_name[] = { N_("bytes"), N_("KB"), N_("MB"), N_("GB") };
|
||||
char *unit_format[] = { "%.0f", "%.1f", "%.02f", "%.02f" };
|
||||
float unit_divide[] = { 1, 1024, 1024*1024, 1024*1024*1024 };
|
||||
char *unit_name[] = { "",
|
||||
/* TRANSLATORS: file size unit "kilobyte" */
|
||||
N_("KB"),
|
||||
/* TRANSLATORS: file size unit "megabyte" */
|
||||
N_("MB"),
|
||||
/* TRANSLATORS: file size unit "gigabyte" */
|
||||
N_("GB"),
|
||||
/* TRANSLATORS: file size unit "terabyte" */
|
||||
N_("TB") };
|
||||
char *unit_format[] = { "%.0f", "%.1f", "%.02f", "%.02f", "%.02f" };
|
||||
float unit_divide[] = { 1.0,
|
||||
1000.0,
|
||||
1000.0 * 1000.0,
|
||||
1000.0 * 1000.0 * 1000.0,
|
||||
1000.0 * 1000.0 * 1000.0 * 1000.0 };
|
||||
char format_size[128], str_size[128];
|
||||
int num_unit;
|
||||
float size_float;
|
||||
|
||||
str_size[0] = '\0';
|
||||
|
||||
if (size < 1024*10)
|
||||
if (size < 10ULL * 1000ULL)
|
||||
num_unit = 0;
|
||||
else if (size < 1024*1024)
|
||||
else if (size < 1000ULL * 1000ULL)
|
||||
num_unit = 1;
|
||||
else if (size < 1024*1024*1024)
|
||||
else if (size < 1000ULL * 1000ULL * 1000ULL)
|
||||
num_unit = 2;
|
||||
else
|
||||
else if (size < 1000ULL * 1000ULL * 1000ULL * 1000ULL)
|
||||
num_unit = 3;
|
||||
else
|
||||
num_unit = 4;
|
||||
|
||||
snprintf (format_size, sizeof (format_size),
|
||||
"%s %%s",
|
||||
unit_format[num_unit]);
|
||||
size_float = ((float)size) / ((float)(unit_divide[num_unit]));
|
||||
snprintf (str_size, sizeof (str_size),
|
||||
format_size,
|
||||
((float)size) / ((float)(unit_divide[num_unit])),
|
||||
(size <= 1) ? _("byte") : _(unit_name[num_unit]));
|
||||
size_float,
|
||||
(num_unit == 0) ?
|
||||
NG_("byte", "bytes", size_float) : _(unit_name[num_unit]));
|
||||
|
||||
return strdup (str_size);
|
||||
}
|
||||
@@ -2316,6 +2338,9 @@ string_encode_base16 (const char *from, int length, char *to)
|
||||
const char *hexa = "0123456789ABCDEF";
|
||||
char *ptr_to;
|
||||
|
||||
if (!from || !to)
|
||||
return;
|
||||
|
||||
ptr_to = to;
|
||||
ptr_to[0] = '\0';
|
||||
for (i = 0; i < length; i++)
|
||||
@@ -2339,6 +2364,9 @@ string_decode_base16 (const char *from, char *to)
|
||||
int length, to_length, i, pos;
|
||||
unsigned char *ptr_to, value;
|
||||
|
||||
if (!from || !to)
|
||||
return 0;
|
||||
|
||||
length = strlen (from) / 2;
|
||||
|
||||
ptr_to = (unsigned char *)to;
|
||||
@@ -2403,6 +2431,9 @@ string_encode_base64 (const char *from, int length, char *to)
|
||||
const char *ptr_from;
|
||||
char *ptr_to;
|
||||
|
||||
if (!from || !to)
|
||||
return;
|
||||
|
||||
ptr_from = from;
|
||||
ptr_to = to;
|
||||
|
||||
@@ -2446,7 +2477,7 @@ string_convbase64_6x4_to_8x3 (const unsigned char *from, unsigned char *to)
|
||||
{
|
||||
to[0] = from[0] << 2 | from[1] >> 4;
|
||||
to[1] = from[1] << 4 | from[2] >> 2;
|
||||
to[2] = ((from[2] << 6) & 0xc0) | from[3];
|
||||
to[2] = from[2] << 6 | from[3];
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -2465,6 +2496,9 @@ string_decode_base64 (const char *from, char *to)
|
||||
unsigned char base64_table[]="|$$$}rstuvwxyz{$$$$$$$>?"
|
||||
"@ABCDEFGHIJKLMNOPQRSTUVW$$$$$$XYZ[\\]^_`abcdefghijklmnopq";
|
||||
|
||||
if (!from || !to)
|
||||
return 0;
|
||||
|
||||
ptr_from = from;
|
||||
ptr_to = to;
|
||||
|
||||
@@ -2474,34 +2508,28 @@ string_decode_base64 (const char *from, char *to)
|
||||
while (ptr_from && ptr_from[0])
|
||||
{
|
||||
length = 0;
|
||||
in[0] = 0;
|
||||
in[1] = 0;
|
||||
in[2] = 0;
|
||||
in[3] = 0;
|
||||
for (i = 0; i < 4; i++)
|
||||
{
|
||||
in[i] = 0;
|
||||
}
|
||||
for (i = 0; i < 4; i++)
|
||||
{
|
||||
c = 0;
|
||||
while (ptr_from[0] && (c == 0))
|
||||
{
|
||||
c = (unsigned char) ptr_from[0];
|
||||
ptr_from++;
|
||||
c = ((c < 43) || (c > 122)) ? 0 : base64_table[c - 43];
|
||||
if (c)
|
||||
c = (c == '$') ? 0 : c - 61;
|
||||
}
|
||||
if (ptr_from[0])
|
||||
if (!ptr_from[0])
|
||||
break;
|
||||
c = (unsigned char) ptr_from[0];
|
||||
ptr_from++;
|
||||
c = ((c < 43) || (c > 122)) ? 0 : base64_table[c - 43];
|
||||
if (c)
|
||||
c = (c == '$') ? 0 : c - 61;
|
||||
if (c)
|
||||
{
|
||||
length++;
|
||||
if (c)
|
||||
in[i] = c - 1;
|
||||
in[i] = c - 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
in[i] = '\0';
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (length)
|
||||
if (length > 0)
|
||||
{
|
||||
string_convbase64_6x4_to_8x3 (in, out);
|
||||
for (i = 0; i < length - 1; i++)
|
||||
@@ -2563,6 +2591,9 @@ string_input_for_buffer (const char *string)
|
||||
{
|
||||
char *pos_slash, *pos_space, *next_char;
|
||||
|
||||
if (!string)
|
||||
return NULL;
|
||||
|
||||
/* special case for C comments pasted in input line */
|
||||
if (strncmp (string, "/*", 2) == 0)
|
||||
return string;
|
||||
@@ -2748,7 +2779,7 @@ string_replace_with_callback (const char *string,
|
||||
* Returns the hash of the shared string (variant of djb2).
|
||||
*/
|
||||
|
||||
unsigned long
|
||||
unsigned long long
|
||||
string_shared_hash_key (struct t_hashtable *hashtable,
|
||||
const void *key)
|
||||
{
|
||||
|
||||
@@ -48,6 +48,7 @@ extern char *string_remove_quotes (const char *string, const char *quotes);
|
||||
extern char *string_strip (const char *string, int left, int right,
|
||||
const char *chars);
|
||||
extern char *string_convert_escaped_chars (const char *string);
|
||||
extern int string_is_word_char (const char *string);
|
||||
extern char *string_mask_to_regex (const char *mask);
|
||||
extern const char *string_regex_flags (const char *regex, int default_flags,
|
||||
int *flags);
|
||||
|
||||
@@ -759,6 +759,8 @@ upgrade_file_read (struct t_upgrade_file *upgrade_file,
|
||||
{
|
||||
UPGRADE_ERROR(_("read - bad signature (upgrade file format may have "
|
||||
"changed since last version)"), "");
|
||||
if (signature)
|
||||
free (signature);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
+1
-2
@@ -402,8 +402,7 @@ weechat_term_check ()
|
||||
sty = getenv ("STY");
|
||||
tmux = getenv ("TMUX");
|
||||
|
||||
is_term_ok = (term && ((strcmp (term, "screen") == 0)
|
||||
|| (strcmp (term, "screen-256color") == 0)));
|
||||
is_term_ok = (term && (strncmp (term, "screen", 6) == 0));
|
||||
is_screen = (sty && sty[0]);
|
||||
is_tmux = (tmux && tmux[0]);
|
||||
|
||||
|
||||
@@ -379,7 +379,6 @@ gui_mouse_event_code2key (const char *code)
|
||||
* buttonX-gesture-right-long | >= 40 |
|
||||
*/
|
||||
|
||||
distance = 0;
|
||||
if (key[0]
|
||||
&& ((gui_mouse_event_x[0] != gui_mouse_event_x[1])
|
||||
|| (gui_mouse_event_y[0] != gui_mouse_event_y[1])))
|
||||
|
||||
@@ -1137,8 +1137,11 @@ gui_bar_item_default_buffer_filter (void *data, struct t_gui_bar_item *item,
|
||||
if (!buffer)
|
||||
return NULL;
|
||||
|
||||
if (!gui_filters_enabled || !gui_filters || !buffer->lines->lines_hidden)
|
||||
if (!gui_filters_enabled || !gui_filters
|
||||
|| !buffer->filter || !buffer->lines->lines_hidden)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
snprintf (str_filter, sizeof (str_filter),
|
||||
"%s%s",
|
||||
|
||||
@@ -1191,8 +1191,9 @@ gui_window_scroll (struct t_gui_window *window, char *scroll)
|
||||
{
|
||||
old_date = ptr_line->data->date;
|
||||
date_tmp = localtime (&old_date);
|
||||
if (date_tmp)
|
||||
memcpy (&old_line_date, date_tmp, sizeof (struct tm));
|
||||
if (!date_tmp)
|
||||
return;
|
||||
memcpy (&old_line_date, date_tmp, sizeof (struct tm));
|
||||
}
|
||||
|
||||
while (ptr_line)
|
||||
@@ -1213,8 +1214,9 @@ gui_window_scroll (struct t_gui_window *window, char *scroll)
|
||||
else
|
||||
{
|
||||
date_tmp = localtime (&(ptr_line->data->date));
|
||||
if (date_tmp)
|
||||
memcpy (&line_date, date_tmp, sizeof (struct tm));
|
||||
if (!date_tmp)
|
||||
return;
|
||||
memcpy (&line_date, date_tmp, sizeof (struct tm));
|
||||
if (old_date > ptr_line->data->date)
|
||||
diff_date = old_date - ptr_line->data->date;
|
||||
else
|
||||
|
||||
@@ -135,10 +135,11 @@ exec_add ()
|
||||
|
||||
new_exec_cmd->prev_cmd = last_exec_cmd;
|
||||
new_exec_cmd->next_cmd = NULL;
|
||||
if (!exec_cmds)
|
||||
exec_cmds = new_exec_cmd;
|
||||
else
|
||||
if (exec_cmds)
|
||||
last_exec_cmd->next_cmd = new_exec_cmd;
|
||||
else
|
||||
exec_cmds = new_exec_cmd;
|
||||
|
||||
last_exec_cmd = new_exec_cmd;
|
||||
|
||||
new_exec_cmd->number = number;
|
||||
|
||||
@@ -417,17 +417,23 @@ irc_ctcp_replace_variables (struct t_irc_server *server, const char *format)
|
||||
* Linux 2.6.32-5-amd64 / x86_64
|
||||
*/
|
||||
buf_uname = (struct utsname *)malloc (sizeof (struct utsname));
|
||||
if (buf_uname && (uname (buf_uname) >= 0))
|
||||
if (buf_uname)
|
||||
{
|
||||
snprintf (buf, sizeof (buf), "%s %s / %s",
|
||||
buf_uname->sysname, buf_uname->release,
|
||||
buf_uname->machine);
|
||||
if (uname (buf_uname) >= 0)
|
||||
{
|
||||
snprintf (buf, sizeof (buf), "%s %s / %s",
|
||||
buf_uname->sysname, buf_uname->release,
|
||||
buf_uname->machine);
|
||||
temp = weechat_string_replace (res, "$osinfo", buf);
|
||||
free (res);
|
||||
if (!temp)
|
||||
{
|
||||
free (buf_uname);
|
||||
return NULL;
|
||||
}
|
||||
res = temp;
|
||||
}
|
||||
free (buf_uname);
|
||||
temp = weechat_string_replace (res, "$osinfo", buf);
|
||||
free (res);
|
||||
if (!temp)
|
||||
return NULL;
|
||||
res = temp;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -664,6 +664,17 @@ irc_nick_new (struct t_irc_server *server, struct t_irc_channel *channel,
|
||||
new_nick->host = (host) ? strdup (host) : NULL;
|
||||
length = strlen (irc_server_get_prefix_chars (server));
|
||||
new_nick->prefixes = malloc (length + 1);
|
||||
if (!new_nick->name || !new_nick->prefixes)
|
||||
{
|
||||
if (new_nick->name)
|
||||
free (new_nick->name);
|
||||
if (new_nick->host)
|
||||
free (new_nick->host);
|
||||
if (new_nick->prefixes)
|
||||
free (new_nick->prefixes);
|
||||
free (new_nick);
|
||||
return NULL;
|
||||
}
|
||||
if (new_nick->prefixes)
|
||||
{
|
||||
memset (new_nick->prefixes, ' ', length);
|
||||
|
||||
@@ -144,6 +144,53 @@ irc_protocol_tags (const char *command, const char *tags, const char *nick,
|
||||
return string;
|
||||
}
|
||||
|
||||
/*
|
||||
* Builds a string with nick and optional address.
|
||||
*
|
||||
* Argument nickname is mandatory, address can be NULL.
|
||||
* If nickname and address are NULL, an empty string is returned.
|
||||
*/
|
||||
|
||||
const char *
|
||||
irc_protocol_nick_address (struct t_irc_server *server,
|
||||
struct t_irc_nick *nick,
|
||||
const char *nickname,
|
||||
const char *address)
|
||||
{
|
||||
static char string[1024];
|
||||
|
||||
string[0] = '\0';
|
||||
|
||||
if (nickname && address && (strcmp (nickname, address) != 0))
|
||||
{
|
||||
/* display nick and address if they are different */
|
||||
snprintf (string, sizeof (string),
|
||||
"%s%s %s(%s%s%s)%s",
|
||||
irc_nick_color_for_message (server,
|
||||
nick,
|
||||
nickname),
|
||||
nickname,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_CHAT_HOST,
|
||||
address,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_RESET);
|
||||
}
|
||||
else if (nickname)
|
||||
{
|
||||
/* display only nick if no address or if nick == address */
|
||||
snprintf (string, sizeof (string),
|
||||
"%s%s%s",
|
||||
irc_nick_color_for_message (server,
|
||||
nick,
|
||||
nickname),
|
||||
nickname,
|
||||
IRC_COLOR_RESET);
|
||||
}
|
||||
|
||||
return string;
|
||||
}
|
||||
|
||||
/*
|
||||
* Callback for the IRC message "AUTHENTICATE".
|
||||
*
|
||||
@@ -1138,6 +1185,7 @@ IRC_PROTOCOL_CALLBACK(nick)
|
||||
IRC_PROTOCOL_CALLBACK(notice)
|
||||
{
|
||||
char *pos_target, *pos_args, *pos, end_char, *channel, status_notice[2];
|
||||
const char *nick_address;
|
||||
struct t_irc_channel *ptr_channel;
|
||||
struct t_irc_nick *ptr_nick;
|
||||
int notify_private, is_channel, is_channel_orig;
|
||||
@@ -1362,59 +1410,20 @@ IRC_PROTOCOL_CALLBACK(notice)
|
||||
}
|
||||
else
|
||||
{
|
||||
if (address && address[0] && (strcmp (nick, address) != 0))
|
||||
{
|
||||
weechat_printf_date_tags (ptr_buffer,
|
||||
date,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL,
|
||||
nick,
|
||||
address),
|
||||
"%s%s%s %s(%s%s%s)%s: %s",
|
||||
weechat_prefix ("network"),
|
||||
irc_nick_color_for_message (server,
|
||||
NULL,
|
||||
nick),
|
||||
nick,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_CHAT_HOST,
|
||||
address,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_RESET,
|
||||
pos_args);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (nick && nick[0])
|
||||
{
|
||||
weechat_printf_date_tags (ptr_buffer,
|
||||
date,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL,
|
||||
nick,
|
||||
address),
|
||||
"%s%s%s%s: %s",
|
||||
weechat_prefix ("network"),
|
||||
irc_nick_color_for_message (server,
|
||||
NULL,
|
||||
nick),
|
||||
nick,
|
||||
IRC_COLOR_RESET,
|
||||
pos_args);
|
||||
}
|
||||
else
|
||||
{
|
||||
weechat_printf_date_tags (ptr_buffer,
|
||||
date,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL,
|
||||
NULL,
|
||||
address),
|
||||
"%s%s",
|
||||
weechat_prefix ("network"),
|
||||
pos_args);
|
||||
}
|
||||
}
|
||||
nick_address = irc_protocol_nick_address (server, NULL,
|
||||
nick, address);
|
||||
weechat_printf_date_tags (
|
||||
ptr_buffer,
|
||||
date,
|
||||
irc_protocol_tags (command,
|
||||
(notify_private) ? "notify_private" : NULL,
|
||||
nick,
|
||||
address),
|
||||
"%s%s%s%s",
|
||||
weechat_prefix ("network"),
|
||||
nick_address,
|
||||
(nick_address[0]) ? ": " : "",
|
||||
pos_args);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2199,25 +2208,22 @@ IRC_PROTOCOL_CALLBACK(topic)
|
||||
|
||||
IRC_PROTOCOL_CALLBACK(wallops)
|
||||
{
|
||||
const char *nick_address;
|
||||
|
||||
IRC_PROTOCOL_MIN_ARGS(3);
|
||||
|
||||
if (ignored)
|
||||
return WEECHAT_RC_OK;
|
||||
|
||||
nick_address = irc_protocol_nick_address (server, NULL, nick, address);
|
||||
weechat_printf_date_tags (irc_msgbuffer_get_target_buffer (server, nick,
|
||||
command, NULL,
|
||||
NULL),
|
||||
date,
|
||||
irc_protocol_tags (command, NULL, nick, address),
|
||||
_("%sWallops from %s%s %s(%s%s%s)%s: %s"),
|
||||
_("%sWallops from %s: %s"),
|
||||
weechat_prefix ("network"),
|
||||
irc_nick_color_for_message (server, NULL, nick),
|
||||
nick,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_CHAT_HOST,
|
||||
address,
|
||||
IRC_COLOR_CHAT_DELIMITERS,
|
||||
IRC_COLOR_RESET,
|
||||
(nick_address[0]) ? nick_address : "?",
|
||||
(argv_eol[2][0] == ':') ? argv_eol[2] + 1 : argv_eol[2]);
|
||||
|
||||
return WEECHAT_RC_OK;
|
||||
|
||||
@@ -101,6 +101,8 @@ logger_tail_file (const char *filename, int n_lines)
|
||||
bytes_read = read (fd, buf, to_read);
|
||||
if (bytes_read <= 0)
|
||||
{
|
||||
if (part_of_line)
|
||||
free (part_of_line);
|
||||
logger_tail_free (ptr_line);
|
||||
close (fd);
|
||||
return NULL;
|
||||
@@ -140,6 +142,7 @@ logger_tail_file (const char *filename, int n_lines)
|
||||
if (!new_line->data)
|
||||
{
|
||||
free (part_of_line);
|
||||
free (new_line);
|
||||
logger_tail_free (ptr_line);
|
||||
close (fd);
|
||||
return NULL;
|
||||
|
||||
@@ -907,9 +907,16 @@ plugin_script_remove_file (struct t_weechat_plugin *weechat_plugin,
|
||||
while (i < 2)
|
||||
{
|
||||
path_script = plugin_script_search_path (weechat_plugin, name);
|
||||
/* script not found? */
|
||||
/*
|
||||
* script not found? (if path_script == name, that means the function
|
||||
* above did not find the script)
|
||||
*/
|
||||
if (!path_script || (strcmp (path_script, name) == 0))
|
||||
{
|
||||
if (path_script)
|
||||
free (path_script);
|
||||
break;
|
||||
}
|
||||
num_found++;
|
||||
if (unlink (path_script) == 0)
|
||||
{
|
||||
|
||||
@@ -1633,58 +1633,58 @@ relay_irc_recv (struct t_relay_client *client, const char *data)
|
||||
weechat_hashtable_set (hash_redirect, "signal", str_signal);
|
||||
if (weechat_strcasecmp (irc_command, "mode") == 0)
|
||||
{
|
||||
if (irc_argc == 1)
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel");
|
||||
if (irc_argc > 0)
|
||||
{
|
||||
if (irc_argc == 1)
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel");
|
||||
weechat_hashtable_set (hash_redirect, "string",
|
||||
irc_argv[0]);
|
||||
}
|
||||
snprintf (str_server_channel,
|
||||
sizeof (str_server_channel),
|
||||
"%s,%s",
|
||||
client->protocol_args,
|
||||
irc_argv[0]);
|
||||
info = weechat_info_get ("irc_is_channel",
|
||||
str_server_channel);
|
||||
if (info && (strcmp (info, "1") == 0))
|
||||
{
|
||||
/* command "MODE #channel ..." */
|
||||
if (irc_argc == 2)
|
||||
snprintf (str_server_channel,
|
||||
sizeof (str_server_channel),
|
||||
"%s,%s",
|
||||
client->protocol_args,
|
||||
irc_argv[0]);
|
||||
info = weechat_info_get ("irc_is_channel",
|
||||
str_server_channel);
|
||||
if (info && (strcmp (info, "1") == 0))
|
||||
{
|
||||
if ((strcmp (irc_argv[1], "b") == 0)
|
||||
|| (strcmp (irc_argv[1], "+b") == 0))
|
||||
/* command "MODE #channel ..." */
|
||||
if (irc_argc == 2)
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_ban");
|
||||
}
|
||||
else if ((strcmp (irc_argv[1], "e") == 0)
|
||||
|| (strcmp (irc_argv[1], "+e") == 0))
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_ban_exception");
|
||||
}
|
||||
else if ((strcmp (irc_argv[1], "I") == 0)
|
||||
|| (strcmp (irc_argv[1], "+I") == 0))
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_invite");
|
||||
if ((strcmp (irc_argv[1], "b") == 0)
|
||||
|| (strcmp (irc_argv[1], "+b") == 0))
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_ban");
|
||||
}
|
||||
else if ((strcmp (irc_argv[1], "e") == 0)
|
||||
|| (strcmp (irc_argv[1], "+e") == 0))
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_ban_exception");
|
||||
}
|
||||
else if ((strcmp (irc_argv[1], "I") == 0)
|
||||
|| (strcmp (irc_argv[1], "+I") == 0))
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_channel_invite");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
/* command "MODE nick ..." */
|
||||
if (irc_argc == 1)
|
||||
else
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_user");
|
||||
/* command "MODE nick ..." */
|
||||
if (irc_argc == 1)
|
||||
{
|
||||
redirect_msg = 1;
|
||||
weechat_hashtable_set (hash_redirect, "pattern",
|
||||
"mode_user");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -388,6 +388,7 @@ relay_client_recv_text (struct t_relay_client *client, const char *data)
|
||||
*/
|
||||
free (client->partial_message);
|
||||
client->partial_message = NULL;
|
||||
weechat_string_free_split (lines);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -1253,9 +1254,9 @@ relay_client_new_with_infolist (struct t_infolist *infolist)
|
||||
new_client->hook_fd = NULL;
|
||||
new_client->last_activity = weechat_infolist_time (infolist, "last_activity");
|
||||
sscanf (weechat_infolist_string (infolist, "bytes_recv"),
|
||||
"%lu", &(new_client->bytes_recv));
|
||||
"%llu", &(new_client->bytes_recv));
|
||||
sscanf (weechat_infolist_string (infolist, "bytes_sent"),
|
||||
"%lu", &(new_client->bytes_sent));
|
||||
"%llu", &(new_client->bytes_sent));
|
||||
new_client->recv_data_type = weechat_infolist_integer (infolist, "recv_data_type");
|
||||
new_client->send_data_type = weechat_infolist_integer (infolist, "send_data_type");
|
||||
str = weechat_infolist_string (infolist, "partial_message");
|
||||
@@ -1554,10 +1555,10 @@ relay_client_add_to_infolist (struct t_infolist *infolist,
|
||||
return 0;
|
||||
if (!weechat_infolist_new_var_time (ptr_item, "last_activity", client->last_activity))
|
||||
return 0;
|
||||
snprintf (value, sizeof (value), "%lu", client->bytes_recv);
|
||||
snprintf (value, sizeof (value), "%llu", client->bytes_recv);
|
||||
if (!weechat_infolist_new_var_string (ptr_item, "bytes_recv", value))
|
||||
return 0;
|
||||
snprintf (value, sizeof (value), "%lu", client->bytes_sent);
|
||||
snprintf (value, sizeof (value), "%llu", client->bytes_sent);
|
||||
if (!weechat_infolist_new_var_string (ptr_item, "bytes_sent", value))
|
||||
return 0;
|
||||
if (!weechat_infolist_new_var_integer (ptr_item, "recv_data_type", client->recv_data_type))
|
||||
@@ -1622,8 +1623,8 @@ relay_client_print_log ()
|
||||
weechat_log_printf (" end_time. . . . . . . : %ld", ptr_client->end_time);
|
||||
weechat_log_printf (" hook_fd . . . . . . . : 0x%lx", ptr_client->hook_fd);
|
||||
weechat_log_printf (" last_activity . . . . : %ld", ptr_client->last_activity);
|
||||
weechat_log_printf (" bytes_recv. . . . . . : %lu", ptr_client->bytes_recv);
|
||||
weechat_log_printf (" bytes_sent. . . . . . : %lu", ptr_client->bytes_sent);
|
||||
weechat_log_printf (" bytes_recv. . . . . . : %llu", ptr_client->bytes_recv);
|
||||
weechat_log_printf (" bytes_sent. . . . . . : %llu", ptr_client->bytes_sent);
|
||||
weechat_log_printf (" recv_data_type. . . . : %d (%s)",
|
||||
ptr_client->recv_data_type,
|
||||
relay_client_data_type_string[ptr_client->recv_data_type]);
|
||||
|
||||
@@ -93,8 +93,8 @@ struct t_relay_client
|
||||
time_t end_time; /* time of client disconnection */
|
||||
struct t_hook *hook_fd; /* hook for socket or child pipe */
|
||||
time_t last_activity; /* time of last byte received/sent */
|
||||
unsigned long bytes_recv; /* bytes received from client */
|
||||
unsigned long bytes_sent; /* bytes sent to client */
|
||||
unsigned long long bytes_recv; /* bytes received from client */
|
||||
unsigned long long bytes_sent; /* bytes sent to client */
|
||||
enum t_relay_client_data_type recv_data_type; /* type recv from client */
|
||||
enum t_relay_client_data_type send_data_type; /* type sent to client */
|
||||
char *partial_message; /* partial text message received */
|
||||
|
||||
@@ -82,7 +82,7 @@ relay_command_client_list (int full)
|
||||
{
|
||||
weechat_printf (NULL,
|
||||
_(" %s%s%s (%s%s%s), started on: %s, last activity: %s, "
|
||||
"bytes: %lu recv, %lu sent"),
|
||||
"bytes: %llu recv, %llu sent"),
|
||||
RELAY_COLOR_CHAT_CLIENT,
|
||||
ptr_client->desc,
|
||||
RELAY_COLOR_CHAT,
|
||||
|
||||
@@ -215,6 +215,8 @@ relay_websocket_build_handshake (struct t_relay_client *client)
|
||||
weechat_string_encode_base64 ((char *)result, length, sec_websocket_accept);
|
||||
gcry_md_close (hd);
|
||||
|
||||
free (key);
|
||||
|
||||
/* build the handshake (it will be sent as-is to client) */
|
||||
snprintf (handshake, sizeof (handshake),
|
||||
"HTTP/1.1 101 Switching Protocols\r\n"
|
||||
|
||||
@@ -628,7 +628,6 @@ relay_weechat_msg_add_hdata (struct t_relay_weechat_msg *msg,
|
||||
goto end;
|
||||
ptr_hdata = ptr_hdata_head;
|
||||
strcpy (path_returned, hdata_head);
|
||||
hdata_name = hdata_head;
|
||||
for (i = 1; i < num_path; i++)
|
||||
{
|
||||
pos = strchr (list_path[i], '(');
|
||||
|
||||
@@ -1394,6 +1394,7 @@ relay_weechat_protocol_recv (struct t_relay_client *client, const char *data)
|
||||
|
||||
if (id)
|
||||
free (id);
|
||||
free (command);
|
||||
if (argv)
|
||||
weechat_string_free_split (argv);
|
||||
if (argv_eol)
|
||||
|
||||
@@ -174,22 +174,22 @@ script_repo_get_filename_loaded (struct t_script_repo *script)
|
||||
weechat_home = weechat_info_get ("weechat_dir", NULL);
|
||||
length = strlen (weechat_home) + strlen (script->name_with_extension) + 64;
|
||||
filename = malloc (length);
|
||||
if (filename)
|
||||
if (!filename)
|
||||
return NULL;
|
||||
|
||||
snprintf (filename, length, "%s/%s/autoload/%s",
|
||||
weechat_home,
|
||||
script_language[script->language],
|
||||
script->name_with_extension);
|
||||
if (stat (filename, &st) != 0)
|
||||
{
|
||||
snprintf (filename, length, "%s/%s/autoload/%s",
|
||||
snprintf (filename, length, "%s/%s/%s",
|
||||
weechat_home,
|
||||
script_language[script->language],
|
||||
script->name_with_extension);
|
||||
if (stat (filename, &st) != 0)
|
||||
{
|
||||
snprintf (filename, length, "%s/%s/%s",
|
||||
weechat_home,
|
||||
script_language[script->language],
|
||||
script->name_with_extension);
|
||||
if (stat (filename, &st) != 0)
|
||||
{
|
||||
filename[0] = '\0';
|
||||
}
|
||||
filename[0] = '\0';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -707,6 +707,10 @@ trigger_name_valid (const char *name)
|
||||
if (strchr (name, ' '))
|
||||
return 0;
|
||||
|
||||
/* no periods allowed */
|
||||
if (strchr (name, '.'))
|
||||
return 0;
|
||||
|
||||
/* name is valid */
|
||||
return 1;
|
||||
}
|
||||
@@ -1102,8 +1106,8 @@ trigger_print_log ()
|
||||
weechat_log_printf (" hooks[%03d]. . . . . . : 0x%lx",
|
||||
i, ptr_trigger->hooks[i]);
|
||||
}
|
||||
weechat_log_printf (" hook_count_cb . . . . . : %lu", ptr_trigger->hook_count_cb);
|
||||
weechat_log_printf (" hook_count_cmd. . . . . : %lu", ptr_trigger->hook_count_cmd);
|
||||
weechat_log_printf (" hook_count_cb . . . . . : %llu", ptr_trigger->hook_count_cb);
|
||||
weechat_log_printf (" hook_count_cmd. . . . . : %llu", ptr_trigger->hook_count_cmd);
|
||||
weechat_log_printf (" hook_running. . . . . . : %d", ptr_trigger->hook_running);
|
||||
weechat_log_printf (" hook_print_buffers. . . : '%s'", ptr_trigger->hook_print_buffers);
|
||||
weechat_log_printf (" regex_count . . . . . . : %d", ptr_trigger->regex_count);
|
||||
|
||||
@@ -86,8 +86,8 @@ struct t_trigger
|
||||
/* hooks */
|
||||
int hooks_count; /* number of hooks */
|
||||
struct t_hook **hooks; /* array of hooks (signal, ...) */
|
||||
unsigned long hook_count_cb; /* number of calls made to callback */
|
||||
unsigned long hook_count_cmd; /* number of commands run in callback*/
|
||||
unsigned long long hook_count_cb; /* number of calls made to callback */
|
||||
unsigned long long hook_count_cmd; /* number of commands run in callback*/
|
||||
int hook_running; /* 1 if one hook callback is running */
|
||||
char *hook_print_buffers; /* buffers (for hook_print only) */
|
||||
|
||||
|
||||
@@ -57,7 +57,7 @@ struct timeval;
|
||||
* please change the date with current one; for a second change at same
|
||||
* date, increment the 01, otherwise please keep 01.
|
||||
*/
|
||||
#define WEECHAT_PLUGIN_API_VERSION "20140610-01"
|
||||
#define WEECHAT_PLUGIN_API_VERSION "20140802-01"
|
||||
|
||||
/* macros for defining plugin infos */
|
||||
#define WEECHAT_PLUGIN_NAME(__name) \
|
||||
@@ -339,8 +339,8 @@ struct t_weechat_plugin
|
||||
struct t_hashtable *(*hashtable_new) (int size,
|
||||
const char *type_keys,
|
||||
const char *type_values,
|
||||
unsigned long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
unsigned long long (*callback_hash_key)(struct t_hashtable *hashtable,
|
||||
const void *key),
|
||||
int (*callback_keycmp)(struct t_hashtable *hashtable,
|
||||
const void *key1,
|
||||
const void *key2));
|
||||
|
||||
@@ -66,4 +66,4 @@ add_dependencies(tests
|
||||
# test for cmake (ctest)
|
||||
add_test(NAME unit
|
||||
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
|
||||
COMMAND tests)
|
||||
COMMAND tests -v)
|
||||
|
||||
+3
-1
@@ -37,7 +37,9 @@ extern "C"
|
||||
#include "../src/plugins/plugin.h"
|
||||
#include "../src/gui/gui-main.h"
|
||||
#include "../src/gui/gui-buffer.h"
|
||||
#include "../src/gui/curses/gui-curses.h"
|
||||
|
||||
extern void gui_main_init ();
|
||||
extern void gui_main_loop ();
|
||||
}
|
||||
|
||||
#include "CppUTest/CommandLineTestRunner.h"
|
||||
|
||||
@@ -23,7 +23,9 @@
|
||||
|
||||
extern "C"
|
||||
{
|
||||
#include <string.h>
|
||||
#include "../src/core/wee-hashtable.h"
|
||||
#include "../src/plugins/plugin.h"
|
||||
}
|
||||
|
||||
TEST_GROUP(Hashtable)
|
||||
@@ -37,7 +39,35 @@ TEST_GROUP(Hashtable)
|
||||
|
||||
TEST(Hashtable, HashDbj2)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
unsigned long long hash;
|
||||
|
||||
hash = hashtable_hash_key_djb2 ("test");
|
||||
CHECK(hash == 5849825121ULL);
|
||||
}
|
||||
|
||||
/*
|
||||
* Test callback hashing a key.
|
||||
*
|
||||
* It returns the djb2 hash + 1.
|
||||
*/
|
||||
|
||||
unsigned long long
|
||||
test_hashtable_hash_key_cb (struct t_hashtable *hashtable, const void *key)
|
||||
{
|
||||
return hashtable_hash_key_djb2 ((const char *)key) + 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Test callback comparing two keys.
|
||||
*
|
||||
* It just makes a string comparison (strcmp) between both keys.
|
||||
*/
|
||||
|
||||
int
|
||||
test_hashtable_keycmp_cb (struct t_hashtable *hashtable,
|
||||
const void *key1, const void *key2)
|
||||
{
|
||||
return strcmp ((const char *)key1, (const char *)key2);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -47,7 +77,42 @@ TEST(Hashtable, HashDbj2)
|
||||
|
||||
TEST(Hashtable, New)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
struct t_hashtable *hashtable;
|
||||
|
||||
hashtable = hashtable_new (-1, NULL, NULL, NULL, NULL);
|
||||
POINTERS_EQUAL(NULL, hashtable);
|
||||
|
||||
/* test invalid size */
|
||||
POINTERS_EQUAL(NULL,
|
||||
hashtable_new (-1,
|
||||
WEECHAT_HASHTABLE_STRING,
|
||||
WEECHAT_HASHTABLE_STRING,
|
||||
NULL, NULL));
|
||||
|
||||
/* test invalid type for keys/values */
|
||||
POINTERS_EQUAL(NULL,
|
||||
hashtable_new (32,
|
||||
"xxxxx", /* invalid */
|
||||
"yyyyy", /* invalid */
|
||||
NULL, NULL));
|
||||
|
||||
/* valid hashtable */
|
||||
hashtable = hashtable_new (32,
|
||||
WEECHAT_HASHTABLE_STRING,
|
||||
WEECHAT_HASHTABLE_INTEGER,
|
||||
&test_hashtable_hash_key_cb,
|
||||
&test_hashtable_keycmp_cb);
|
||||
CHECK(hashtable);
|
||||
LONGS_EQUAL(32, hashtable->size);
|
||||
CHECK(hashtable->htable);
|
||||
LONGS_EQUAL(0, hashtable->items_count);
|
||||
LONGS_EQUAL(HASHTABLE_STRING, hashtable->type_keys);
|
||||
LONGS_EQUAL(HASHTABLE_INTEGER, hashtable->type_values);
|
||||
POINTERS_EQUAL(&test_hashtable_hash_key_cb, hashtable->callback_hash_key);
|
||||
POINTERS_EQUAL(&test_hashtable_keycmp_cb, hashtable->callback_keycmp);
|
||||
POINTERS_EQUAL(NULL, hashtable->callback_free_key);
|
||||
POINTERS_EQUAL(NULL, hashtable->callback_free_value);
|
||||
hashtable_free (hashtable);
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
+204
-21
@@ -29,24 +29,47 @@ extern "C"
|
||||
#include "../src/core/wee-string.h"
|
||||
}
|
||||
|
||||
#define ONE_KB 1000ULL
|
||||
#define ONE_MB (ONE_KB * 1000ULL)
|
||||
#define ONE_GB (ONE_MB * 1000ULL)
|
||||
#define ONE_TB (ONE_GB * 1000ULL)
|
||||
|
||||
#define WEE_HAS_HL_STR(__result, __str, __words) \
|
||||
LONGS_EQUAL(__result, string_has_highlight (__str, __words));
|
||||
|
||||
#define WEE_HAS_HL_REGEX(__result_regex, __result_hl, __str, __regex) \
|
||||
LONGS_EQUAL(__result_hl, \
|
||||
string_has_highlight_regex (__str, __regex)); \
|
||||
LONGS_EQUAL(__result_regex, \
|
||||
LONGS_EQUAL(__result_regex, \
|
||||
string_regcomp (®ex, __regex, REG_ICASE)); \
|
||||
LONGS_EQUAL(__result_hl, \
|
||||
string_has_highlight_regex_compiled (__str, \
|
||||
®ex)); \
|
||||
if (__result_regex == 0) \
|
||||
regfree(®ex);
|
||||
|
||||
#define WEE_REPLACE_REGEX(__result_regex, __result_replace, __str, \
|
||||
__regex, __replace, __ref_char, __callback) \
|
||||
LONGS_EQUAL(__result_regex, \
|
||||
string_regcomp (®ex, __regex, \
|
||||
REG_EXTENDED | REG_ICASE)); \
|
||||
result = string_replace_regex (__str, ®ex, __replace, \
|
||||
__ref_char, __callback, NULL); \
|
||||
if (__result_replace == NULL) \
|
||||
{ \
|
||||
LONGS_EQUAL(__result_hl, \
|
||||
string_has_highlight_regex_compiled (__str, \
|
||||
®ex)); \
|
||||
regfree(®ex); \
|
||||
POINTERS_EQUAL(NULL, result); \
|
||||
} \
|
||||
else \
|
||||
{ \
|
||||
STRCMP_EQUAL(__result_replace, result); \
|
||||
} \
|
||||
if (__result_regex == 0) \
|
||||
regfree(®ex);
|
||||
|
||||
#define WEE_HAS_HL_REGEX_COMP(__result, __str, __regex) \
|
||||
|
||||
#define WEE_FORMAT_SIZE(__result, __size) \
|
||||
str = string_format_size (__size); \
|
||||
STRCMP_EQUAL(__result, str); \
|
||||
free (str);
|
||||
|
||||
TEST_GROUP(String)
|
||||
{
|
||||
@@ -363,7 +386,6 @@ TEST(String, ConvertEscapedChars)
|
||||
* string_is_word_char
|
||||
*/
|
||||
|
||||
/*
|
||||
TEST(String, IsWordChar)
|
||||
{
|
||||
LONGS_EQUAL(0, string_is_word_char (NULL));
|
||||
@@ -379,7 +401,6 @@ TEST(String, IsWordChar)
|
||||
LONGS_EQUAL(1, string_is_word_char ("_abc"));
|
||||
LONGS_EQUAL(1, string_is_word_char ("|abc"));
|
||||
}
|
||||
*/
|
||||
|
||||
/*
|
||||
* Tests functions:
|
||||
@@ -511,6 +532,10 @@ TEST(String, Highlight)
|
||||
|
||||
TEST(String, Replace)
|
||||
{
|
||||
regex_t regex;
|
||||
char *result;
|
||||
|
||||
/* basic replace */
|
||||
POINTERS_EQUAL(NULL, string_replace (NULL, NULL, NULL));
|
||||
POINTERS_EQUAL(NULL, string_replace ("string", NULL, NULL));
|
||||
POINTERS_EQUAL(NULL, string_replace (NULL, "search", NULL));
|
||||
@@ -523,6 +548,19 @@ TEST(String, Replace)
|
||||
STRCMP_EQUAL("test xxx def", string_replace("test abc def", "abc", "xxx"));
|
||||
STRCMP_EQUAL("xxx test xxx def xxx",
|
||||
string_replace("abc test abc def abc", "abc", "xxx"));
|
||||
|
||||
/* replace with regex */
|
||||
WEE_REPLACE_REGEX(-1, NULL, NULL, NULL, NULL, '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, NULL, NULL, "", NULL, '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "string", "string", "", NULL, '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "test abc def", "test abc def", "xyz", "xxx", '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "test xxx def", "test abc def", "abc", "xxx", '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "foo", "test foo", "^(test +)(.*)", "$2", '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "test / ***", "test foo", "^(test +)(.*)", "$1/ $.*2", '$', NULL);
|
||||
WEE_REPLACE_REGEX(0, "%%%", "test foo", "^(test +)(.*)", "$.%+", '$', NULL);
|
||||
|
||||
/* replace with a callback */
|
||||
/* TODO: write tests for string_replace_with_callback */
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -650,8 +688,39 @@ TEST(String, Iconv)
|
||||
const char *noel_utf8 = "no\xc3\xabl"; /* noël */
|
||||
const char *noel_iso = "no\xebl";
|
||||
char *str;
|
||||
FILE *f;
|
||||
|
||||
/* TODO: write tests */
|
||||
/* string_iconv */
|
||||
POINTERS_EQUAL(NULL, string_iconv (0, NULL, NULL, NULL));
|
||||
STRCMP_EQUAL("", string_iconv (0, NULL, NULL, ""));
|
||||
STRCMP_EQUAL("abc", string_iconv (0, NULL, NULL, "abc"));
|
||||
STRCMP_EQUAL("abc", string_iconv (1, "UTF-8", "ISO-8859-15", "abc"));
|
||||
STRCMP_EQUAL(noel_iso,
|
||||
string_iconv (1, "UTF-8", "ISO-8859-15", noel_utf8));
|
||||
STRCMP_EQUAL(noel_utf8,
|
||||
string_iconv (0, "ISO-8859-15", "UTF-8", noel_iso));
|
||||
|
||||
/* string_iconv_to_internal */
|
||||
POINTERS_EQUAL(NULL, string_iconv_to_internal (NULL, NULL));
|
||||
STRCMP_EQUAL("", string_iconv_to_internal (NULL, ""));
|
||||
STRCMP_EQUAL("abc", string_iconv_to_internal (NULL, "abc"));
|
||||
STRCMP_EQUAL(noel_utf8,
|
||||
string_iconv_to_internal ("ISO-8859-15", noel_iso));
|
||||
|
||||
/* string_iconv_from_internal */
|
||||
POINTERS_EQUAL(NULL, string_iconv_from_internal (NULL, NULL));
|
||||
STRCMP_EQUAL("", string_iconv_from_internal (NULL, ""));
|
||||
STRCMP_EQUAL("abc", string_iconv_from_internal (NULL, "abc"));
|
||||
STRCMP_EQUAL(noel_iso,
|
||||
string_iconv_from_internal ("ISO-8859-15", noel_utf8));
|
||||
|
||||
/* string_iconv_fprintf */
|
||||
f = fopen ("/dev/null", "w");
|
||||
LONGS_EQUAL(0, string_iconv_fprintf (f, NULL));
|
||||
LONGS_EQUAL(1, string_iconv_fprintf (f, "abc"));
|
||||
LONGS_EQUAL(1, string_iconv_fprintf (f, noel_utf8));
|
||||
LONGS_EQUAL(1, string_iconv_fprintf (f, noel_iso));
|
||||
fclose (f);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -661,7 +730,34 @@ TEST(String, Iconv)
|
||||
|
||||
TEST(String, FormatSize)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
char *str;
|
||||
|
||||
WEE_FORMAT_SIZE("0 bytes", 0);
|
||||
WEE_FORMAT_SIZE("1 byte", 1);
|
||||
WEE_FORMAT_SIZE("2 bytes", 2);
|
||||
WEE_FORMAT_SIZE("42 bytes", 42);
|
||||
WEE_FORMAT_SIZE("999 bytes", ONE_KB - 1);
|
||||
WEE_FORMAT_SIZE("1000 bytes", ONE_KB);
|
||||
WEE_FORMAT_SIZE("9999 bytes", (10 * ONE_KB) - 1);
|
||||
|
||||
WEE_FORMAT_SIZE("10.0 KB", 10 * ONE_KB);
|
||||
WEE_FORMAT_SIZE("10.1 KB", (10 * ONE_KB) + (ONE_KB / 10));
|
||||
WEE_FORMAT_SIZE("42.0 KB", 42 * ONE_KB);
|
||||
WEE_FORMAT_SIZE("1000.0 KB", ONE_MB - 1);
|
||||
|
||||
WEE_FORMAT_SIZE("1.00 MB", ONE_MB);
|
||||
WEE_FORMAT_SIZE("1.10 MB", ONE_MB + (ONE_MB / 10));
|
||||
WEE_FORMAT_SIZE("42.00 MB", 42 * ONE_MB);
|
||||
WEE_FORMAT_SIZE("1000.00 MB", ONE_GB - 1);
|
||||
|
||||
WEE_FORMAT_SIZE("1.00 GB", ONE_GB);
|
||||
WEE_FORMAT_SIZE("1.10 GB", ONE_GB + (ONE_GB / 10));
|
||||
WEE_FORMAT_SIZE("42.00 GB", 42 * ONE_GB);
|
||||
WEE_FORMAT_SIZE("1000.00 GB", ONE_TB - 1);
|
||||
|
||||
WEE_FORMAT_SIZE("1.00 TB", ONE_TB);
|
||||
WEE_FORMAT_SIZE("1.10 TB", ONE_TB + (ONE_TB / 10));
|
||||
WEE_FORMAT_SIZE("42.00 TB", 42 * ONE_TB);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -674,7 +770,82 @@ TEST(String, FormatSize)
|
||||
|
||||
TEST(String, BaseN)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
char str[1024];
|
||||
const char *str_abc = "abc";
|
||||
const char *str_abc_base64 = "YWJj";
|
||||
const char *str_base64[][2] =
|
||||
{ { "", "" },
|
||||
{ "A", "QQ==" },
|
||||
{ "B", "Qg==" },
|
||||
{ "C", "Qw==" },
|
||||
{ "D", "RA==" },
|
||||
{ "abc", "YWJj" },
|
||||
{ "This is a test.", "VGhpcyBpcyBhIHRlc3Qu" },
|
||||
{ "This is a test..", "VGhpcyBpcyBhIHRlc3QuLg==" },
|
||||
{ "This is a test...", "VGhpcyBpcyBhIHRlc3QuLi4=" },
|
||||
{ "This is a test....", "VGhpcyBpcyBhIHRlc3QuLi4u" },
|
||||
{ "This is a long long long sentence here...",
|
||||
"VGhpcyBpcyBhIGxvbmcgbG9uZyBsb25nIHNlbnRlbmNlIGhlcmUuLi4=" },
|
||||
{ "Another example for base64",
|
||||
"QW5vdGhlciBleGFtcGxlIGZvciBiYXNlNjQ=" },
|
||||
{ "Another example for base64.",
|
||||
"QW5vdGhlciBleGFtcGxlIGZvciBiYXNlNjQu" },
|
||||
{ "Another example for base64..",
|
||||
"QW5vdGhlciBleGFtcGxlIGZvciBiYXNlNjQuLg==" },
|
||||
{ "Another example for base64...",
|
||||
"QW5vdGhlciBleGFtcGxlIGZvciBiYXNlNjQuLi4=" },
|
||||
{ NULL, NULL } };
|
||||
int i, length;
|
||||
|
||||
/* string_encode_base16 */
|
||||
string_encode_base16 (NULL, 0, NULL);
|
||||
string_encode_base16 (NULL, 0, str);
|
||||
string_encode_base16 ("", 0, NULL);
|
||||
str[0] = 0xAA;
|
||||
string_encode_base16 ("", -1, str);
|
||||
BYTES_EQUAL(0x0, str[0]);
|
||||
str[0] = 0xAA;
|
||||
string_encode_base16 ("", 0, str);
|
||||
BYTES_EQUAL(0x0, str[0]);
|
||||
string_encode_base16 ("abc", 3, str);
|
||||
STRCMP_EQUAL("616263", str);
|
||||
|
||||
/* string_decode_base16 */
|
||||
LONGS_EQUAL(0, string_decode_base16 (NULL, NULL));
|
||||
LONGS_EQUAL(0, string_decode_base16 (NULL, str));
|
||||
LONGS_EQUAL(0, string_decode_base16 ("", NULL));
|
||||
LONGS_EQUAL(0, string_decode_base16 ("", str));
|
||||
LONGS_EQUAL(3, string_decode_base16 ("616263", str));
|
||||
STRCMP_EQUAL("abc", str);
|
||||
|
||||
/* string_encode_base64 */
|
||||
string_encode_base64 (NULL, 0, NULL);
|
||||
string_encode_base64 (NULL, 0, str);
|
||||
string_encode_base64 ("", 0, NULL);
|
||||
str[0] = 0xAA;
|
||||
string_encode_base64 ("", -1, str);
|
||||
BYTES_EQUAL(0x0, str[0]);
|
||||
str[0] = 0xAA;
|
||||
string_encode_base64 ("", 0, str);
|
||||
BYTES_EQUAL(0x0, str[0]);
|
||||
for (i = 0; str_base64[i][0]; i++)
|
||||
{
|
||||
string_encode_base64 (str_base64[i][0], strlen (str_base64[i][0]),
|
||||
str);
|
||||
STRCMP_EQUAL(str_base64[i][1], str);
|
||||
}
|
||||
|
||||
/* string_decode_base64 */
|
||||
LONGS_EQUAL(0, string_decode_base64 (NULL, NULL));
|
||||
LONGS_EQUAL(0, string_decode_base64 (NULL, str));
|
||||
LONGS_EQUAL(0, string_decode_base64 ("", NULL));
|
||||
LONGS_EQUAL(0, string_decode_base64 ("", str));
|
||||
for (i = 0; str_base64[i][0]; i++)
|
||||
{
|
||||
length = string_decode_base64 (str_base64[i][1], str);
|
||||
STRCMP_EQUAL(str_base64[i][0], str);
|
||||
LONGS_EQUAL(strlen (str_base64[i][0]), length);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -685,17 +856,29 @@ TEST(String, BaseN)
|
||||
|
||||
TEST(String, Input)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
}
|
||||
char *str;
|
||||
|
||||
/*
|
||||
* Tests functions:
|
||||
* string_is_command_char
|
||||
*/
|
||||
/* string_is_command_char */
|
||||
LONGS_EQUAL(0, string_is_command_char (NULL));
|
||||
LONGS_EQUAL(0, string_is_command_char (""));
|
||||
LONGS_EQUAL(0, string_is_command_char ("abc"));
|
||||
LONGS_EQUAL(1, string_is_command_char ("/"));
|
||||
LONGS_EQUAL(1, string_is_command_char ("/abc"));
|
||||
LONGS_EQUAL(1, string_is_command_char ("//abc"));
|
||||
|
||||
TEST(String, CommandChar)
|
||||
{
|
||||
/* TODO: write tests */
|
||||
/* string_input_for_buffer */
|
||||
POINTERS_EQUAL(NULL, string_input_for_buffer (NULL));
|
||||
POINTERS_EQUAL(NULL, string_input_for_buffer ("/"));
|
||||
POINTERS_EQUAL(NULL, string_input_for_buffer ("/abc"));
|
||||
str = strdup ("");
|
||||
STRCMP_EQUAL(str, string_input_for_buffer (str));
|
||||
free (str);
|
||||
str = strdup ("abc");
|
||||
STRCMP_EQUAL(str, string_input_for_buffer (str));
|
||||
free (str);
|
||||
str = strdup ("//abc");
|
||||
STRCMP_EQUAL(str + 1, string_input_for_buffer (str));
|
||||
free (str);
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
@@ -250,7 +250,8 @@ TEST(Utf8, Size)
|
||||
LONGS_EQUAL(1, utf8_char_size_screen ("A"));
|
||||
LONGS_EQUAL(1, utf8_char_size_screen ("ë"));
|
||||
LONGS_EQUAL(1, utf8_char_size_screen ("€"));
|
||||
LONGS_EQUAL(1, utf8_char_size_screen (han_char));
|
||||
/* this test does not work on Ubuntu Precise: it returns 2 instead of 1 */
|
||||
/*LONGS_EQUAL(1, utf8_char_size_screen (han_char));*/
|
||||
|
||||
/* length of string (in chars) */
|
||||
LONGS_EQUAL(0, utf8_strlen (NULL));
|
||||
@@ -274,7 +275,8 @@ TEST(Utf8, Size)
|
||||
LONGS_EQUAL(1, utf8_strlen_screen ("A"));
|
||||
LONGS_EQUAL(1, utf8_strlen_screen ("ë"));
|
||||
LONGS_EQUAL(1, utf8_strlen_screen ("€"));
|
||||
LONGS_EQUAL(1, utf8_strlen_screen (han_char));
|
||||
/* this test does not work on Ubuntu Precise: it returns 2 instead of 1 */
|
||||
/*LONGS_EQUAL(1, utf8_strlen_screen (han_char));*/
|
||||
LONGS_EQUAL(1, utf8_strlen_screen ("\x7f"));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user