Daily Sync #403
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: Daily Sync | |
on: | |
schedule: | |
- cron: '0 0 * * *' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: actions/setup-node@v1 | |
with: | |
node-version: 12.x | |
- name: Clone, install Sabaki, and update translation files | |
run: | | |
npm install | |
git clone --depth 1 https://github.com/SabakiHQ/Sabaki ./.tmp/Sabaki | |
cd ./.tmp/Sabaki | |
npm install | |
npm run i18n | |
cp ./i18n/*.i18n.js ../../src | |
npx dolm update ./i18n/template.i18n.js "../../src/*.i18n.js" "!../../src/en.i18n.js" | |
- name: Perform sync | |
run: | | |
node ./ci/dailySync.js | |
npm run update-readme | |
npm run format | |
git config --local user.email "[email protected]" | |
git config --local user.name "GitHub Action" | |
git diff | |
git commit -m "Daily Sync" -a | |
echo Done. | |
shell: bash {0} | |
- name: Push changes | |
uses: ad-m/[email protected] | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} |