Backup Image #215
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: Backup Image | |
on: | |
workflow_dispatch: | |
schedule: | |
# 每周一 02:00 UTC 时间 | |
- cron: '0 2 ? * MON' | |
push: | |
paths: | |
# MarkDown 文件变化 | |
- 'blogs/**.md' | |
jobs: | |
hello_world_job: | |
runs-on: ubuntu-latest | |
name: Auto backup image | |
steps: | |
- uses: actions/checkout@v1 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 18.13.0 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 7.24.3 | |
run_install: true | |
- name: Backup image | |
uses: ./backup-img-action # Uses an action in the root directory | |
with: | |
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }} |