Skip to content

Commit 5dc6759

Browse files
committed
Add workflow to deploy web version
1 parent e112a0c commit 5dc6759

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

.github/workflows/pages.yml

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Deploy web version
2+
3+
on:
4+
push:
5+
branches: [$default-branch]
6+
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
concurrency:
15+
group: "pages"
16+
cancel-in-progress: false
17+
18+
jobs:
19+
deploy:
20+
environment:
21+
name: github-pages
22+
url: ${{ steps.deployment.outputs.page_url }}
23+
runs-on: ubuntu-latest
24+
steps:
25+
- name: Checkout
26+
uses: actions/checkout@v4
27+
28+
- name: Install Nix
29+
uses: cachix/install-nix-action@v27
30+
31+
- name: Run the Magic Nix Cache
32+
uses: DeterminateSystems/magic-nix-cache-action@v7
33+
34+
- name: Setup flake environment
35+
run: nix develop -c sleep 0
36+
shell: bash
37+
38+
- name: Build web version
39+
run: nix develop -c make build-web
40+
shell: bash
41+
42+
- name: Setup Pages
43+
uses: actions/configure-pages@v5
44+
45+
- name: Upload artifact
46+
uses: actions/upload-pages-artifact@v3
47+
with:
48+
path: './build'
49+
50+
- name: Deploy to GitHub Pages
51+
id: deployment
52+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)