Skip to content

Commit

Permalink
fix _n:
Browse files Browse the repository at this point in the history
  • Loading branch information
bluebat committed Dec 10, 2020
1 parent 45f40a5 commit 73bb575
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 8 deletions.
2 changes: 1 addition & 1 deletion cmn.po
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ msgid "message regular expression"
msgstr "訊息正規表示式"

msgid "force messages fuzzy-free"
msgstr "強制訊息除去模糊"
msgstr "強制除去模糊標記"

msgid "keep translated msgstr"
msgstr "備註翻譯過的 msgstr"
Expand Down
1 change: 1 addition & 0 deletions cmn2yue.dic
Original file line number Diff line number Diff line change
Expand Up @@ -10222,6 +10222,7 @@ cmn|yue
樣品|示範
樣品米|米辦
樣品酒|酒辦
樣子很醜|好樣衰
樣子時髦|時款
樣子|樣
樣本|板
Expand Down
20 changes: 16 additions & 4 deletions eng2cmn.dic
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
5.1-channel|5.1 聲道
64-bit|64 位元
64-bit edition|64 位元版
7.1-channel|7.1 聲道
8-bit|8 位元
8 bit clean|不含第八位元
a|
Expand Down Expand Up @@ -1869,7 +1870,7 @@ check for|檢查有無
check if|檢查是否
checking program|查驗程式
check in|簽入
check key|核對鍵
check key|檢核鍵
checklist|檢核列表
check mark|勾選標記
check out|簽出
Expand Down Expand Up @@ -3870,6 +3871,7 @@ expenditure|開支
expense|費用
experience|經驗
experimental|實驗性質
experiment|實驗
expertise|專業知識
experts only|專家限用
expert|專家
Expand Down Expand Up @@ -4037,6 +4039,7 @@ feminine ordinal indicator|陰性序數指示符
fetch|擷取
fewer|更少的
few more|多一點
few people|很少人
few seconds|數秒
few|幾個
fiber distributed data interface|光纖分散式資料介面
Expand Down Expand Up @@ -4228,7 +4231,7 @@ fluctuation|變動
fluent|流利
fluidness|流暢度
fluid|溶液
flush|清理
flush|沖寫
flyer|傳單
flying height|飛行高度
fly through|掃視
Expand Down Expand Up @@ -4350,7 +4353,8 @@ forwardonly|順向
forward references|後述參考
forward reference|向前參考
forwards|向前
forward|轉寄
forward|前進
forward:|轉寄:
for yes|表示同意
for your information|供您參考
for you|為您
Expand Down Expand Up @@ -5505,6 +5509,7 @@ in spite of this|儘管如此
in spite of|儘管
in %s second|於 %s 秒後
installation|安裝
installed size|安裝後大小
installed"|已安裝
installed|已安裝的
installer|安裝程式
Expand Down Expand Up @@ -5884,6 +5889,7 @@ keep|保持
kelvin|凱氏
kenyan|肯亞
kenya|肯亞
kernel panic|內核崩壞
kernel-tunable|內核可調的
kernel|內核
kern|字間微調
Expand Down Expand Up @@ -6470,7 +6476,7 @@ lookup|查找
look up|查閱
look|外觀
loopback mount|回送掛載
loopback|迴路
loopback|回送
looping|循環
loop|迴圈
loose binding|寬鬆繫結
Expand Down Expand Up @@ -6604,6 +6610,7 @@ make a gift|送一份禮物
make a goal|達陣
make a|做出
make featured|定為特色
makefile|建置檔
make it better|讓它更好
make link|建立鏈結
make no sense|不具任何意義
Expand All @@ -6618,6 +6625,7 @@ makes|使得
make up|構成
make use of|利用
make visible|顯現
"make"|建置
make|製作
malagasy|馬達加斯加語
malawi|馬拉威
Expand Down Expand Up @@ -7793,6 +7801,7 @@ one place down|向下一個位置
one place up|向上一個位置
one second|一秒鐘
one stop|一次滿足
one suspects that|一般認為
one-way-recovery|單向復原
one way|單向
one|一個
Expand Down Expand Up @@ -8119,6 +8128,7 @@ panama|巴拿馬
panel|面板
pane|窗格
pangasinan|龐加辛南語
pangolin|穿山甲
panic|驚恐
panning|平移
pannonian|潘諾尼亞
Expand Down Expand Up @@ -9176,6 +9186,7 @@ refinement|重整化
refine|重整
reflection|映像
reflect|反映
refocus|重新聚焦
reformat|重新格式
refresh rate|重刷速率
refresh|重刷
Expand Down Expand Up @@ -12590,6 +12601,7 @@ worksheet|工作表
workshop|工作室
works like a charm|有神奇功效
workspace pager|工作區切換器
workspace-specific|工作區特定的
workspace|工作區
workstation|工作站
work together|合作
Expand Down
2 changes: 1 addition & 1 deletion msgchi.1
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ Define keyboard accelerator used in input file, default '_&' for po.
.SS "Output details: (only with --type=po and without --expression)"
.TP
\fB\-F\fR, \fB\-\-fuzzyfree\fR
Remove fuzzy entries of all messages.
Remove fuzzy marks of all messages.
.TP
\fB\-k\fR, \fB\-\-keep\fR
Keep translated msgstr as remark in output file.
Expand Down
2 changes: 1 addition & 1 deletion msgchi.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ def eng2chi(self, content):
if re.search(r'\w{2,};\w{2,};\w{2,};', content): #protect semicolon separator
content = re.sub(r';', r';;', content)
content = re.sub(r'([a-z])\(s\)', r'\1', content) #remove plural mark
content = re.sub(r'_n?:.*\\n', r'', content) #remove comment
content = re.sub(r'^_n?:[^\\]*\\n', r'', content) #remove comment
if arguments.opts.accelerator:
if '_' in arguments.opts.accelerator and re.match(r'(_[A-Za-z]|[^_]*[A-Za-z]_|[^_]*\W_[A-Za-z])[Ka-z][^_]*$', content) and re.search(r'[A-Z]', content) and not re.search(r'%\([a-z]*_[a-z]*\)', content):
replacement = r'\1\2 (_'+content[content.find('_')+1].upper()+')'
Expand Down
2 changes: 1 addition & 1 deletion msgchi.spec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ URL: https://github.com/bluebat/msgchi
Source0: https://github.com/bluebat/msgchi/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildArch: noarch
BuildRequires: python3-devel
Requires: python3, gettext
Requires: python3, gettext, msghack

%description
msgchi is a Python3 script to help translators of chinese locales
Expand Down
3 changes: 3 additions & 0 deletions zhc2cmn.dic
Original file line number Diff line number Diff line change
Expand Up @@ -1649,6 +1649,8 @@ zh_cn|cmn
样|樣
核实|查核
核电站|核能電廠
核聚变|核融合
核裂变|核分裂
根证书|主要認證
格式符|格式子
格林纳达|格瑞那達
Expand Down Expand Up @@ -2503,6 +2505,7 @@ zh_cn|cmn
肠|腸
肤|膚
肮|骯
肯尼迪|甘迺迪
肴|餚
肾|腎
胀|脹
Expand Down

0 comments on commit 73bb575

Please sign in to comment.