-
Notifications
You must be signed in to change notification settings - Fork 0
51 lines (49 loc) · 1.75 KB
/
vercel.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
50
51
name: Vercel
on:
workflow_dispatch:
jobs:
deployment:
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Setup Python
id: python
uses: actions/setup-python@v4
with:
python-version: "3.11"
- name: Install Dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Download Excel SpreedSheet
run: curl -Lo excel.xlsx https://docs.google.com/spreadsheets/d/1by2mZB4-ixVfRAu-_mcRxyQEJGuSfbzPkh-AlrUPCLY/export?format=xlsx
- name: Download CSV
run: curl -Lo collection.csv https://docs.google.com/spreadsheets/d/1by2mZB4-ixVfRAu-_mcRxyQEJGuSfbzPkh-AlrUPCLY/export?format=csv
- name: Create SQLite Database
run: sqlite-utils insert collection.db collection collection.csv --csv
- name: Deploy to Vercel
env:
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
run: |-
datasette publish vercel collection.db \
--branch main \
--metadata metadata.json \
--token $VERCEL_TOKEN \
--project naruto-shippuden-datasette-stefan-dev-de \
--install datasette-render-image-tags \
--public
- name: Delete Previous Release
continue-on-error: true
run: gh release delete latest --cleanup-tag --yes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create Release
run: |-
gh release create latest \
--latest \
--title "Release" \
--notes "**Version**: $(date +"%Y%m%d")-git-${GITHUB_SHA:0:7}" \
"excel.xlsx"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}