Update Translations #965
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 | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the master branch | |
on: | |
schedule: | |
# * is a special character in YAML so you have to quote this string | |
- cron: '21 3 * * *' | |
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | |
jobs: | |
# This workflow contains a single job called "build" | |
build: | |
# The type of runner that the job will run on | |
runs-on: ubuntu-latest | |
# Steps represent a sequence of tasks that will be executed as part of the job | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- uses: BSFishy/pip-action@v1 | |
with: | |
packages: virtualenv | |
# Runs a set of commands using the runners shell | |
- name: Update Translations | |
shell: bash | |
env: | |
GDOC_CLIENT_SECRET: ${{ secrets.GDOC_CLIENT_SECRET }} | |
run: | | |
cd scripts/spreadsheet_to_resource_mds/ | |
echo Creating client secret... | |
echo $GDOC_CLIENT_SECRET > client_secret.json | |
echo Switching into virtual Python3 environment... | |
virtualenv -p python3 env | |
echo Sourcing environment... | |
source env/bin/activate | |
echo Installing requirements... | |
pip3 install -r requirements.txt | |
echo Updating all bitcoin resources from spreadsheet... | |
./update_all.sh | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v3 | |
with: | |
title: 'chore(db): update translations' | |
reviewers: dergigi |