You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

cron-translations.yml 1.5KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. name: cron-translations
  2. on:
  3. schedule:
  4. - cron: "7 0 * * *" # every day at 00:07 UTC
  5. workflow_dispatch:
  6. jobs:
  7. crowdin-pull:
  8. runs-on: ubuntu-latest
  9. if: github.repository == 'go-gitea/gitea'
  10. steps:
  11. - uses: actions/checkout@v4
  12. - name: download from crowdin
  13. uses: docker://jonasfranz/crowdin
  14. env:
  15. CROWDIN_KEY: ${{ secrets.CROWDIN_KEY }}
  16. PLUGIN_DOWNLOAD: true
  17. PLUGIN_EXPORT_DIR: options/locale/
  18. PLUGIN_IGNORE_BRANCH: true
  19. PLUGIN_PROJECT_IDENTIFIER: gitea
  20. - name: update locales
  21. run: ./build/update-locales.sh
  22. - name: push translations to repo
  23. uses: appleboy/git-push-action@v0.0.2
  24. with:
  25. author_email: "teabot@gitea.io"
  26. author_name: GiteaBot
  27. branch: main
  28. commit: true
  29. commit_message: "[skip ci] Updated translations via Crowdin"
  30. remote: "git@github.com:go-gitea/gitea.git"
  31. ssh_key: ${{ secrets.DEPLOY_KEY }}
  32. crowdin-push:
  33. runs-on: ubuntu-latest
  34. if: github.repository == 'go-gitea/gitea'
  35. steps:
  36. - uses: actions/checkout@v4
  37. - name: push translations to crowdin
  38. uses: docker://jonasfranz/crowdin
  39. env:
  40. CROWDIN_KEY: ${{ secrets.CROWDIN_KEY }}
  41. PLUGIN_UPLOAD: true
  42. PLUGIN_EXPORT_DIR: options/locale/
  43. PLUGIN_IGNORE_BRANCH: true
  44. PLUGIN_PROJECT_IDENTIFIER: gitea
  45. PLUGIN_FILES: |
  46. locale_en-US.ini: options/locale/locale_en-US.ini
  47. PLUGIN_BRANCH: main