Skip to content

Update i18n deploy #22639

Update i18n deploy

Update i18n deploy #22639

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@9bb56186c3b09b4f86b1c65136769dd318469633 # tag: v4.1.2
- uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # tag: v4.0.2
with:
node-version: 20
- name: Install dependencies
uses: bahmutov/npm-install@237ded403e6012a48281f4572eab0c8eafe55b3f # tag: v1.10.1
- 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: Add Docusaurus problem matcher
run: echo "::add-matcher::.github/problem-matchers/docusaurus.json"
- 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 }}