summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorVaxry <vaxry@vaxry.net>2025-11-16 20:14:38 +0000
committerVaxry <vaxry@vaxry.net>2025-11-16 20:22:07 +0000
commite948445f6ecd24b330af4cf07a046f44e4d10297 (patch)
tree009d8c5347cffbbc50ccce23c0810e8d41d0ca52 /.github
parent7a6177532bc5bff01805ff8ffe0aa3d68c0b085e (diff)
CI: minor translation fixes
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/translation-ai-check.yml21
1 files changed, 15 insertions, 6 deletions
diff --git a/.github/workflows/translation-ai-check.yml b/.github/workflows/translation-ai-check.yml
index 1b4636b2..81019a41 100644
--- a/.github/workflows/translation-ai-check.yml
+++ b/.github/workflows/translation-ai-check.yml
@@ -4,8 +4,6 @@ on:
pull_request_target:
types:
- opened
- paths:
- - 'src/i18n/**'
issue_comment:
types:
- created
@@ -29,11 +27,22 @@ jobs:
AI_PROMPT: Translation patch below.
steps:
+ - uses: dorny/paths-filter@v3
+ id: changes
+ with:
+ filters: |
+ i18n:
+ - 'src/i18n/**'
+
+ - name: Stop if i18n not changed
+ if: steps.changes.outputs.i18n != 'true'
+ run: echo "No i18n changes in this PR; skipping." && exit 0
+
- name: Determine PR number
id: pr
run: |
if [ "${{ github.event_name }}" = "pull_request_target" ]; then
- echo "number=${{ github.event.pull_request_target.number }}" >> "$GITHUB_OUTPUT"
+ echo "number=${{ github.event.pull_request.number }}" >> "$GITHUB_OUTPUT"
else
echo "number=${{ github.event.issue.number }}" >> "$GITHUB_OUTPUT"
fi
@@ -112,9 +121,9 @@ jobs:
fi
# If failed, add a note
- $ADDITIONAL_NOTE = ""
- if [[ $COMMENT == *"not ok"* ]]; then
- $ADDITIONAL_NOTE = "\n\nPlease note this check is a guideline, not a hard requirement. It is here to help you translate. If you disagree with some points, just state that. Any typos should be fixed."
+ ADDITIONAL_NOTE=""
+ if [[ "$COMMENT" == *"not ok"* ]]; then
+ ADDITIONAL_NOTE="\n\nPlease note this check is a guideline, not a hard requirement. It is here to help you translate. If you disagree with some points, just state that. Any typos should be fixed."
fi
# Post the review as a PR comment