Skip to content

Commit d73154a

Browse files
authored
Update the translation script to follow new path rules (#4)
1 parent 8d6995f commit d73154a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

docs/src/scripts/translate.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,10 @@ You must return **only** the translated markdown. Do not include any commentary,
308308
- Keep all placeholders such as \`CODE_BLOCK_*\` and \`CODE_LINE_PREFIX\` unchanged.
309309
- Don't add any tags before/after lines using astrojs items such as <Code> and their imports
310310
- Treat the **Do‑Not‑Translate list** and **Term‑Specific list** as case‑insensitive; preserve the original casing you see.
311-
- Convert the relative path starting with /guides/* to /${langCode}/guides/*
311+
- Convert path in the following rules:
312+
- Replace /openai-agents-js/XXX/* with /openai-agents-js/${langCode}/XXX/*
313+
- When the path starts with /openai-agents-js/openai/, don't change anything
314+
- Don't change the first /openai-agents-js/ part in any case
312315
- Skip translation for:
313316
- Inline code surrounded by single back‑ticks ( \`like_this\` ).
314317
- Fenced code blocks delimited by \`\`\` or ~~~, including all comments inside them.

0 commit comments

Comments
 (0)