Skip to content

Commit

Permalink
Update main.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
BonjourFeng authored Feb 6, 2024
1 parent 95c1696 commit d41a4d6
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
name: Run Python script and update image

on:
schedule:
- cron: '0 3 * * *' # 每天凌晨3点运行
push:
branches:
- main # 或者你想要运行这个工作流的分支
Expand All @@ -16,7 +18,15 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: 3.8

- name: Install Fontist
uses: fontist/setup-fontist@v1
with:
fontist-token: ${{ secrets.GH_TOKEN }}

- name: Install HYWenHei font
run: fontist install "HYWenHei"

- name: Install dependencies
run: |
Expand All @@ -32,4 +42,4 @@ jobs:
git config --local user.name "GitHub Action"
git add .
git diff --quiet && git diff --staged --quiet || git commit -m "Update image"
git push --allow-unrelated-histories
git push -f origin main

0 comments on commit d41a4d6

Please sign in to comment.