weblate-pull.yml 723 B

1234567891011121314151617181920212223242526272829303132
  1. name: Weblate Pull Branch
  2. on:
  3. workflow_dispatch:
  4. pull_request_target:
  5. branches:
  6. - 'dev'
  7. types: [ closed ]
  8. release:
  9. types:
  10. - published
  11. jobs:
  12. weblate:
  13. runs-on: ubuntu-latest
  14. if: github.event.pull_request.merged == true || github.event.action == 'published' || github.event_name == 'workflow_dispatch'
  15. steps:
  16. - name: Checkout
  17. uses: actions/checkout@v4
  18. - name: Setup Python
  19. uses: actions/setup-python@v5
  20. with:
  21. python-version: '3.13.3'
  22. - name: Install wlc
  23. run: pip install wlc
  24. - name: Update Repository
  25. env:
  26. WEBLATE_TOKEN: ${{ secrets.WEBLATE_TOKEN }}
  27. run: wlc --key $WEBLATE_TOKEN pull