-
Notifications
You must be signed in to change notification settings - Fork 21
50 lines (45 loc) · 1.14 KB
/
deploy.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
name: Deploy site
on:
push:
branches:
- main
permissions:
contents: write
pages: write
id-token: write
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up Python 3.12
uses: actions/[email protected]
with:
python-version: 3.12
- name: Install Poetry
run: curl -sSL https://install.python-poetry.org | python -
- name: Install dependencies with Poetry
run: poetry install
- name: Generate MDX
run: poetry run python bin/site.py -v
- name: Use Node.js 22.x
uses: actions/setup-node@v3
with:
node-version: 22.x
- name: Export site
run: |
npm install
npm run build
working-directory: website
- name: Deploy
run: |
git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
npm run deploy -- -u "github-actions-bot <[email protected]>"
working-directory: website
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}