Update i18n deploy #22191
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 i18n deploy' | |
on: | |
schedule: | |
- cron: '0 0,12 * * *' | |
permissions: | |
contents: read | |
jobs: | |
deploy: | |
name: 'Build and deploy localized site' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # tag: v3.3.0 | |
- name: Use Node.js 16 | |
uses: actions/setup-node@64ed1c7eab4cce3362f8c340dee64e5eaeef8f7c # tag: v3.6.0 | |
with: | |
node-version: 16 | |
- name: Install dependencies | |
uses: bahmutov/npm-install@8add8c6d2c8586964896d9fdc639e021312a643f # tag: v1.8.28 | |
- name: Download crowdin translation | |
run: yarn i18n:download | |
env: | |
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} | |
- name: Update Crowdin glossary | |
run: yarn i18n:glossary | |
env: | |
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }} | |
# TODO: figure out if this can be re-enabled? | |
# - name: Download cache | |
# run: ./scripts/bin/azcopy copy "https://electronwebsite.blob.core.windows.net/%24web/*?$SAS" "./build" --recursive | |
# env: | |
# SAS: ${{ secrets.SAS }} | |
- name: Build | |
run: yarn i18n:build | |
- name: Deploy | |
run: ./scripts/bin/azcopy copy "./build/*" "https://electronwebsite.blob.core.windows.net/%24web?$SAS" --recursive | |
env: | |
SAS: ${{ secrets.SAS }} |