forked from antfu-collective/sponsorkit
-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (40 loc) · 1.08 KB
/
main.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Scheduler
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * *'
push:
branches: [ main ]
jobs:
update-sponsors:
runs-on: ubuntu-latest
env:
SPONSORKIT_AFDIAN_USER_ID: ${{ secrets.AFDIAN_ID }}
SPONSORKIT_AFDIAN_TOKEN: ${{ secrets.AFDIAN_TOKEN }}
SPONSORKIT_AFDIAN_EXECHANGERATE: '1'
AFDIAN_EXECHANGERATE: '1'
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v2
- name: Set node
uses: actions/setup-node@v4
with:
node-version: lts/*
cache: pnpm
- name: Setup
run: npm i -g @antfu/ni
- name: Install
run: nci
- name: Build Sponsorkit
run: nr build
- name: Run Sponsorkit script
run: node ./dist/cli.cjs
- name: Upload
uses: Teahouse-Studios/[email protected]
with:
KEY_ID: ${{ secrets.KEY_ID }}
KEY_SECRET: ${{ secrets.KEY_SECRET }}
BUCKET: frontend-wdljt
LOCAL_PATH: ./sponsorkit/
REMOTE_PREFIX: meme/sponsors/