Skip to content

Auto Generate

Auto Generate #1222

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: Auto Generate
on:
schedule:
- cron: "0 0 * * *" # scheduled at 06:00 (UTC+8) every monday
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Generate
run: |
pip install requests
python3 ./scripts/build-node.py
- name: Commit
run: |
git config --global user.email [email protected]
git config --global user.name 'GitHub Actions'
git diff-index --quiet HEAD -- && echo "No changes to commit" || (git add . && git commit -m "daily update" -a && git push)
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}