Skip to content
Merged
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
61 changes: 61 additions & 0 deletions .github/workflows/translate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: "Update translations"

on:
workflow_dispatch:
schedule:
- cron: "0 3 * * *"

permissions: {}

defaults:
run:
shell: pwsh

jobs:
update-translations:
permissions:
# for git push
contents: write
runs-on: ubuntu-latest

env:
TX_TOKEN: ${{ secrets.TX_TOKEN }}

steps:
- uses: actions/checkout@v4
with:
ssh-key: ${{ secrets.DEPLOYMENT_SSH_KEY }}
submodules: recursive
ref: "main"

- name: install-deps
run: sudo apt install -y qt6-l10n-tools

- name: l10n-remove-old
run: |
rm translations/*.ts
git checkout translations/desktop_en.ts

- name: l10n-read
run: /usr/lib/qt6/bin/lupdate src -no-obsolete -ts translations/desktop_en.ts

- name: l10n-push-source
uses: transifex/cli-action@v2
with:
token: ${{ secrets.TX_TOKEN }}
args: push -s --silent

- name: fix-transifex-action
run: rm -rf /tmp/tx

- name: l10n-pull
uses: transifex/cli-action@v2
with:
token: ${{ secrets.TX_TOKEN }}
args: pull --force --all --silent

- uses: GuillaumeFalourd/git-commit-push@v1.3
with:
email: devops@opencloud.eu
name: OpenCloud
commit_message: "[tx] updated translations from transifex"
Loading