Skip to content

Expire sponsor block #13

Expire sponsor block

Expire sponsor block #13

name: Expire sponsor block
on:
schedule:
# 00:05 in Asia/Shanghai.
- cron: "5 16 * * *"
workflow_dispatch:
permissions:
contents: write
jobs:
remove-sponsor:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Remove expired sponsor block
run: python3 .github/scripts/expire_sponsor.py
- name: Commit README update
run: |
if git diff --quiet; then
echo "No README changes to commit."
exit 0
fi
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git add README.md
git commit -m "Remove expired sponsor block"
git push