-
Notifications
You must be signed in to change notification settings - Fork 2
33 lines (33 loc) · 1.08 KB
/
api.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
name: Deploy API
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
on:
push:
branches:
- main
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v3
with:
repository: myst-templates/.github
path: readme
token: ${{ secrets.PAT }}
- run: npm install
- run: npm run build:cli
- run: npm run link
- name: Clone and index templates
run: myst-templates-api index data/tex.yml data/docx.yml data/site.yml data/typst.yml
- run: npm run build
- run: vercel deploy --prod --token=${{ secrets.VERCEL_TOKEN }}
- name: Update organization readme
run: |
cd readme
git config --local user.name 'myst-templates[bot]'
git config --local user.email 'myst-templates[bot]@users.noreply.github.com'
git commit profile/README.md -m '📖 Update templates table' || echo "🧹 No changes!"
git push origin || echo "🧹 No changes!"