Update Translations #1694
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: Update Translations | |
on: | |
schedule: | |
- cron: "0 1 * * *" | |
workflow_dispatch: | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
update: | |
permissions: | |
contents: write # for peter-evans/create-pull-request to create branch | |
pull-requests: write # for peter-evans/create-pull-request to create a PR | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
ref: 'master' | |
submodules: true | |
- name: Setup PHP | |
uses: shivammathur/[email protected] | |
with: | |
php-version: '8.1' | |
tools: composer | |
- name: Setup Node.js | |
uses: actions/[email protected] | |
with: | |
node-version: 18 | |
- name: Setup submodules | |
run: git submodule init && git submodule update --force --rebase | |
- name: Install Composer | |
run: cd _backend && composer install | |
- name: Install | |
run: npm ci | |
- name: Build | |
run: npm run build | |
- name: Update | |
run: php _backend/Console/Translation.php | |
- name: Create Pull Request | |
id: cpr | |
uses: peter-evans/create-pull-request@v7 | |
with: | |
commit-message: "Automatic update of translations files from source" | |
title: "Automatic update of translations files from source" | |
branch: "update-translations-from-source" | |
- name: Check outputs | |
run: | | |
echo "Pull Request Number - ${{ steps.cpr.outputs.pull-request-number }}" |