Skip to content

Commit f427d13

Browse files
Fix mismatch of messages found by checkPoFiles() (#5878)
* Fix checkPoFiles issues * Mention checkPoFiles() in CRAN_Release * apply suggested improvement
1 parent 4a466bc commit f427d13

File tree

3 files changed

+13
-16
lines changed

3 files changed

+13
-16
lines changed

.dev/CRAN_Release.cmd

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,7 @@ Rscript -e "tools::update_pkg_po('.')"
2121
## [or perhaps, if we get several languages, each to open
2222
## its own PR and merge to main translation PR]
2323

24-
## 3) Check validity
25-
## update_pkg_po('.') to be run again for the PR
26-
## [can this be done via Travis?]
24+
## 3) Check validity with tools::checkPoFiles("zh_CN")
2725

2826
###############################################
2927
# Basic checks

po/R-zh_CN.po

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -129,8 +129,7 @@ msgid ""
129129
"'between' function the 'x' argument is a POSIX class while '%s' was not, "
130130
"coercion to POSIX failed with: %s"
131131
msgstr ""
132-
"'between' 中的 'x' 参数为 POSIX 类,而 'lower' 并不是,将 'lower' 自动转换成 "
133-
"POSIX 失败:%s"
132+
"'between' 中的 'x' 参数为 POSIX 类,而 '%s' 并不是,将其强制转换成 POSIX 时失败:%s"
134133

135134
#: between.R:27
136135
#, c-format
@@ -670,7 +669,7 @@ msgid ""
670669
"%d; the same length as there are rows in x (after subsetting if i is "
671670
"provided)."
672671
msgstr ""
673-
"在'by'或'keyby'列表中的项长度为 %s (%s)。每一项的长度须均为%d,即应与 x (或经 i "
672+
"在'by'或'keyby'列表中的项长度为 %s 。每一项的长度须均为%d,即应与 x (或经 i "
674673
"筛选后的子集)中所包含行数相同。"
675674

676675
#: data.table.R:940
@@ -976,7 +975,7 @@ msgstr ""
976975
msgid ""
977976
"rownames is TRUE but key has multiple columns %s; taking first column x[,1] "
978977
"as rownames"
979-
msgstr "rownames 为 TRUE但键(key)为多个列;将使用第一列 x[,1] 为行名。"
978+
msgstr "rownames 为 TRUE但键(key)为多个列 %s;将使用第一列 x[,1] 为行名。"
980979

981980
#: data.table.R:2043
982981
#, c-format
@@ -1293,7 +1292,7 @@ msgid ""
12931292
"setDT again."
12941293
msgstr ""
12951294
"无法通过引用直接将 '%1$s' 转换成 data.table,因其与所在环境已绑定。 这有很大"
1296-
"可能是因为 '%1%s' 存在于一个包(或环境)中,该包(或环境)已被锁定从而无法修"
1295+
"可能是因为 '%1$s' 存在于一个包(或环境)中,该包(或环境)已被锁定从而无法修"
12971296
"改其绑定的变量。可以尝试将该对象复制到你的现有环境中,如:var <- copy(var)"
12981297
"然后再运行 setDT。"
12991298

@@ -1326,9 +1325,9 @@ msgid ""
13261325
"profile of input lengths (length:frequency) is: %s\n"
13271326
"The first entry with fewer than %d entries is %d."
13281327
msgstr ""
1329-
"'setDT' 参数 'x' 中所有的元素均须为同一长度,但输入元素的长度频数表(长度:频
1330-
数)为:%s\n"
1331-
"x中第一个长度比 %s 少的元素为第 %d 项。"
1328+
"'setDT' 参数 'x' 中所有的元素均须为同一长度,但输入元素的长度频数表(长度:频"
1329+
"数)为:%s\n"
1330+
"x中第一个长度比 %d 少的元素为第 %d 项。"
13321331

13331332
#: data.table.R:2911
13341333
#, c-format
@@ -2129,8 +2128,8 @@ msgid ""
21292128
"constitute the start to a valid YAML header (expecting something matching "
21302129
"regex \"%s\"); please check your input and try again."
21312130
msgstr ""
2132-
"在第一个未被跳过的行 (%d) 中遇到 <%s%s>。它不是一个有效的 YAML 文件头的开头"
2133-
"(有效的开头应符合正则表达式 \"%s\");请检查你的输入并重试。"
2131+
"在第一个未被跳过的行 (%3$d) 中遇到 <%1$s%2$s>。它不是一个有效的 YAML 文件头的开头"
2132+
"(有效的开头应符合正则表达式 \"%4$s\");请检查你的输入并重试。"
21342133

21352134
#: fread.R:193
21362135
#, c-format
@@ -2790,7 +2789,7 @@ msgstr "列中包含空白"
27902789
#: setkey.R:51 setkey.R:281
27912790
#, c-format
27922791
msgid "some columns are not in the data.table: %s"
2793-
msgstr "一些列不在data.table中:%"
2792+
msgstr "一些列不在data.table中:%s"
27942793

27952794
#: setkey.R:73 setkey.R:282
27962795
#, c-format
@@ -3097,7 +3096,7 @@ msgstr "测试于 %s 后失败,失败发生在测试 %s 之后、下一 test()
30973096
#: test.data.table.R:186
30983097
#, c-format
30993098
msgid "%d error(s) out of %d. Search %s for test number(s) %s. Duration: %s."
3100-
msgstr "%2$d 中共产生 %1$d 个错误。搜索 %s 以定位测试编号 %s。用时:%s。"
3099+
msgstr "%2$d 中共产生 %1$d 个错误。搜索 %3$s 以定位测试编号 %4$s。用时:%5$s。"
31013100

31023101
#: test.data.table.R:199
31033102
#, c-format

po/zh_CN.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1244,7 +1244,7 @@ msgstr "'na'长度是%<PRId64>但长度必须是1或者等于'test'的长度 (%<
12441244
msgid ""
12451245
"'no' is of type %s but '%s' is %s. Please make all arguments have the same "
12461246
"type."
1247-
msgstr "'no' 是 %s 类型,但 'no' 是 %s 类型。请确保所有参数为同一类型。"
1247+
msgstr "'no' 是 %s 类型,但 '%s' 是 %s 类型。请确保所有参数为同一类型。"
12481248

12491249
#: fifelse.c:52
12501250
#, c-format

0 commit comments

Comments
 (0)