Skip to content

Commit 85660f7

Browse files
fix: transifex push/pull (#11900)
1 parent 5887dc2 commit 85660f7

File tree

2 files changed

+15
-62
lines changed

2 files changed

+15
-62
lines changed

.github/workflows/run-in-docker.sh

Lines changed: 0 additions & 32 deletions
This file was deleted.

.github/workflows/translate.yml

Lines changed: 15 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ jobs:
2424
steps:
2525
- uses: actions/checkout@v4
2626
with:
27+
ssh-key: ${{ secrets.DEPLOYMENT_SSH_KEY }}
2728
submodules: recursive
2829
ref: "master"
2930

@@ -38,36 +39,20 @@ jobs:
3839
- name: l10n-read
3940
run: /usr/lib/qt6/bin/lupdate src -no-obsolete -ts translations/client_en.ts
4041

41-
- name: l10n-push
42-
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
43-
# we need to use a different docker image for those two, this appears to be a bit tricky with github actions out of the box
44-
run: bash .github/workflows/run-in-docker.sh owncloudci/transifex:latest "cd translations && tx push -s --skip"
42+
- name: l10n-push-source
43+
uses: transifex/cli-action@v2
44+
with:
45+
token: ${{ secrets.TX_TOKEN }}
46+
args: push -s --skip
4547

4648
- name: l10n-pull
47-
run: bash .github/workflows/run-in-docker.sh owncloudci/transifex:latest "cd translations && tx pull --force --skip --all"
48-
49-
- name: l10n-clean
50-
run: git checkout translations/.tx/config
51-
52-
- name: update-repo-before-commit
53-
run: |
54-
git status
55-
git add translations/client_*.ts
56-
git status
57-
git stash
58-
git pull --ff-only origin
49+
uses: transifex/cli-action@v2
50+
with:
51+
token: ${{ secrets.TX_TOKEN }}
52+
args: pull --force --skip --all
5953

60-
- name: commit and push
61-
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
62-
run: |
63-
if(git stash list) {
64-
git stash pop
65-
install -d -m 0700 ~/.ssh
66-
Set-Content -Value "${{ secrets.DEPLOYMENT_SSH_KEY }}" -Path ~/.ssh/id_ed25519
67-
chmod 0600 ~/.ssh/id_ed25519
68-
git config user.name "ownClouders"
69-
git config user.email "[email protected]"
70-
git add translations/
71-
git commit -m "[tx] updated client translations from transifex [skip ci]"
72-
git push [email protected]:owncloud/client.git
73-
}
54+
- uses: GuillaumeFalourd/[email protected]
55+
with:
56+
57+
name: ownClouders
58+
commit_message: "[tx] updated translations from transifex"

0 commit comments

Comments
 (0)