@@ -90,76 +90,25 @@ jobs:
9090 You are working on the CPython sync PR #${{ steps.find-pr.outputs.pr_number }}
9191 on the `cron/sync/3.14` branch.
9292
93- Your task is to translate new fuzzy and untranslated entries in PO files.
94-
95- ## Step 1: Find entries that need work
96-
97- Use `msgattrib` to find files with fuzzy or untranslated entries:
98- ```
99- msgattrib --fuzzy --only-fuzzy <file> to find fuzzy entries
100- msgattrib --untranslated --only-untranslated <file> to find untranslated entries
101- ```
102-
103- Focus on files changed in this PR first:
104- ```
105- git diff --name-only origin/3.14...HEAD -- '*.po'
106- ```
107-
108- ## Step 2: Prioritize fuzzy entries
109-
110- Fuzzy entries already have a base translation that needs updating.
111- Compare the old msgid (`#|`) with the new msgid and update the translation.
112- Remove the `#, fuzzy` flag and `#|` comments after fixing.
113-
114- ## Step 3: Translate untranslated entries
115-
116- For entries with empty msgstr, provide new translations.
117-
118- ## Translation rules
119-
120- Follow these rules strictly:
121- - Use Traditional Chinese (zh-TW), NEVER simplified Chinese (zh-CN)
122- - Fullwidth punctuation for Chinese: 。,「」()
123- - Add space between Chinese and English text
124- - Preserve all reST markup (:func:, :mod:, :class:, :ref:, :term: etc.)
125- - Keep these terms in English: int, float, str, bytes, list, tuple, dict, set, iterator, generator, iterable, pickle
126- - Use correct zh-TW terms: 建立(not 創建), 程式碼(not 代碼), 資訊(not 信息), 模組(not 模塊), 預設(not 默認), 呼叫(not 調用), 回傳(not 返回), 函式(not 函數), 變數(not 變量), 實作(not 實現), 資料(not 數據)
127- - Line length <= 79 characters in PO files
128-
129- ## Step 4: Wrap and validate
130-
131- After editing, run powrap on changed files:
132- ```
133- uvx powrap <file>
134- ```
135-
136- Validate with:
137- ```
138- msgfmt --check <file>
139- ```
140-
141- ## Step 5: Commit and push
142-
143- Stage changed PO files and commit:
144- ```
145- git add <changed .po files>
146- git commit -m "Translate fuzzy and untranslated entries from sync"
147- git push
148- ```
149-
150- ## Step 6: Post summary
151-
152- Post a comment on PR #${{ steps.find-pr.outputs.pr_number }} summarizing:
153- - Number of fuzzy entries fixed
154- - Number of new translations added
155- - Files modified
156- - Any entries skipped (and why)
157-
158- Use:
159- ```
160- gh pr comment ${{ steps.find-pr.outputs.pr_number }} --body "<summary>"
161- ```
162-
163- If there are no fuzzy or untranslated entries to process, post a short
164- comment saying the sync PR has no entries needing translation and skip
165- the commit/push steps.
93+ Your task: translate fuzzy and untranslated entries in changed PO files.
94+ Follow the translate-po and fix-fuzzy skills for translation rules and fuzzy resolution.
95+
96+ Steps:
97+ 1. Find changed PO files: `git diff --name-only origin/3.14...HEAD -- '*.po'`
98+ 2. For each file, use `msgattrib --only-fuzzy` and `msgattrib --only-untranslated` to find entries
99+ 3. Prioritize fuzzy entries first (use fix-fuzzy skill), then untranslated (use translate-po skill)
100+ 4. After editing, run `uvx powrap <file>` and `msgfmt --check <file>`
101+ 5. Commit and push:
102+ ```
103+ git add <changed .po files>
104+ git commit -m "Translate fuzzy and untranslated entries from sync"
105+ git push
106+ ```
107+ 6. Post a summary comment on PR #${{ steps.find-pr.outputs.pr_number }} with:
108+ - Fuzzy entries fixed count
109+ - New translations added count
110+ - Files modified
111+ - Entries skipped (if any, with reasons)
112+ Use: `gh pr comment ${{ steps.find-pr.outputs.pr_number }} --body "<summary>"`
113+
114+ If no entries need work, post a short "nothing to translate" comment and skip commit/push.
0 commit comments