Skip to content

Commit 39e0b08

Browse files
authored
Pulling translations works on forks if TX_TOKEN is set (#83748)
1 parent 919322e commit 39e0b08

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/workflows/build-translations.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ jobs:
1515
run: sudo apt-get install gettext
1616

1717
- name: Install Transifex CLI
18-
if: github.repository == 'CleverRaven/Cataclysm-DDA'
1918
run: |
2019
curl -sL https://github.com/transifex/cli/releases/download/v1.6.17/tx-linux-amd64.tar.gz | sudo tar zxvf - -C /usr/bin tx
2120
@@ -30,11 +29,16 @@ jobs:
3029
fetch-depth: 1
3130

3231
- name: Pull translations
33-
if: github.repository == 'CleverRaven/Cataclysm-DDA'
32+
continue-on-error: true
3433
env:
3534
TX_TOKEN: ${{ secrets.TX_TOKEN }}
36-
run: tx pull -a --force
37-
35+
run: |
36+
if [ -z "${TX_TOKEN}" ]; then
37+
echo "No TX_TOKEN secret set in this repo, not pulling translations from Transifex"
38+
exit 1
39+
fi
40+
tx pull -a --force
41+
3842
- name: Discard invalid translations
3943
run: ./lang/discard_invalid_po.sh
4044

0 commit comments

Comments
 (0)