add auto update action #2
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: Font update | |
on: | |
schedule: | |
- cron: '0 0 * * 0' | |
push: | |
branches: | |
- main | |
jobs: | |
generate-and-push: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.12 | |
- name: Generate fonts | |
run: | | |
sudo apt install woff2 | |
python -m pip install requests | |
python generator.py | |
- name: Commit and push changes | |
run: | | |
git config user.name "GitHub Actions" | |
git config user.email "[email protected]" | |
git add . | |
git commit -m "Weekly font update" | |
git push |