-
Notifications
You must be signed in to change notification settings - Fork 4
30 lines (27 loc) · 1.1 KB
/
transifex-pull.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
name: "Pull from transifex"
on:
schedule:
- cron: "0 */12 * * *"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
pull-strings-from-transifex:
name: pull-strings-from-transifex
runs-on: ubuntu-latest
steps:
- name: Granting private modules access
run: |
git config --global url."https://${{ secrets.CI_PRIVATE_REPOS_GH_TOKEN }}:[email protected]/".insteadOf "https://github.com/"
- uses: actions/checkout@v4
- name: "Pull new translations"
env:
TX_TOKEN: ${{ secrets.TX_TOKEN }}
run: |
curl -o- https://raw.githubusercontent.com/transifex/cli/master/install.sh | bash
source /home/runner/.bashrc
export PATH="/home/runner/work/lantern-client/lantern-client:$PATH"
tx pull -af -minimum-perc 90
git config user.name git
git config user.email [email protected]
git ls-files --modified assets/locales android/app/src/main/res | xargs git add
git diff --cached --exit-code || git commit -m "updated translations..." && git push origin main