Skip to content

Download from crowdin #3587

Download from crowdin

Download from crowdin #3587

name: Download from crowdin
on:
workflow_dispatch:
schedule:
- cron: 0 * * * *
jobs:
download:
runs-on: ubuntu-latest
# secrets cannot be accessed inside an `if` so this needs to be checked in separate job
name: dowload
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: master
- name: Install crowdin cli
run: |
wget -qO - https://artifacts.crowdin.com/repo/GPG-KEY-crowdin | sudo apt-key add -
echo "deb https://artifacts.crowdin.com/repo/deb/ /" | sudo tee -a /etc/apt/sources.list.d/crowdin.list
sudo apt-get update && sudo apt-get install crowdin3
- name: Download translations
shell: bash
run: |
crowdin download --all
env:
CROWDIN_API_KEY: ${{ secrets.CROWDIN_API_KEY }}
- uses: tibdex/github-app-token@v2
id: generate-token
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
- name: Create Pull Request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ steps.generate-token.outputs.token }}
commit-message: "PO files added."
branch: auto/crowdin
title: "Update translations"
add-paths: "**.po"