Skip to content

Scheduler

Scheduler #335

Workflow file for this run

name: Scheduler
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
push:
branches: [main]
jobs:
update-sponsors:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v4
with:
node-version: lts/*
cache: pnpm
- name: Install deps
run: pnpm i --frozen-lockfile
- name: Update sponsors
run: pnpm exec sponsorkit -w 800 --dir . && pnpm exec sponsorkit -w 1000 --name sponsors.wide --dir .
env:
SPONSORKIT_GITHUB_LOGIN: DIYgod
SPONSORKIT_GITHUB_TOKEN: ${{ secrets.SPONSORKIT_GITHUB_TOKEN }}
SPONSORKIT_AFDIAN_USER_ID: ${{ secrets.SPONSORKIT_AFDIAN_USER_ID }}
SPONSORKIT_AFDIAN_TOKEN: ${{ secrets.SPONSORKIT_AFDIAN_TOKEN }}
SPONSORKIT_PATREON_TOKEN: ${{ secrets.SPONSORKIT_PATREON_TOKEN }}
SPONSORKIT_OPENCOLLECTIVE_KEY: ${{ secrets.SPONSORKIT_OPENCOLLECTIVE_KEY }}
SPONSORKIT_OPENCOLLECTIVE_SLUG: ${{ secrets.SPONSORKIT_OPENCOLLECTIVE_SLUG }}
- name: Update sponsors - simple
run: pnpm exec sponsorkit -w 1000 --name sponsors.simple --dir .
env:
SPONSORKIT_TYPE: simple
SPONSORKIT_GITHUB_LOGIN: DIYgod
SPONSORKIT_GITHUB_TOKEN: ${{ secrets.SPONSORKIT_GITHUB_TOKEN }}
SPONSORKIT_AFDIAN_USER_ID: ${{ secrets.SPONSORKIT_AFDIAN_USER_ID }}
SPONSORKIT_AFDIAN_TOKEN: ${{ secrets.SPONSORKIT_AFDIAN_TOKEN }}
SPONSORKIT_PATREON_TOKEN: ${{ secrets.SPONSORKIT_PATREON_TOKEN }}
SPONSORKIT_OPENCOLLECTIVE_KEY: ${{ secrets.SPONSORKIT_OPENCOLLECTIVE_KEY }}
SPONSORKIT_OPENCOLLECTIVE_SLUG: ${{ secrets.SPONSORKIT_OPENCOLLECTIVE_SLUG }}
- name: Commit
uses: EndBug/add-and-commit@v9
with:
message: 'chore: update sponsors.svg'
add: 'sponsors.*'
author_name: DIYgod-bot
author_email: [email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}