Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/check-weblate-prs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Block EN Merges on Active Weblate PRs

on:
pull_request:
paths:
- 'wiki/en/**'

jobs:
check-weblate:
name: Evaluate Weblate PR Status
runs-on: ubuntu-24.04-arm
permissions:
pull-requests: read

steps:
- name: Check for open Weblate pull requests
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO: ${{ github.repository }}
run: |
WEBLATE_AUTHOR="weblate"

echo "Checking $REPO for open PRs from $WEBLATE_AUTHOR..."

OPEN_PRS=$(gh pr list --repo "$REPO" --state open --author "$WEBLATE_AUTHOR" --json number -q '. | length')

if [ "$OPEN_PRS" -gt 0 ]; then
echo "::error::Found $OPEN_PRS open Weblate PR(s). Merging changes to English documentation is blocked to prevent po4a translation conflicts."
exit 1
else
echo "No open Weblate PRs detected. Safe to proceed."
exit 0
fi
Loading