Skip to content

Commit 26ca54d

Browse files
committed
update deployment
1 parent ff97e00 commit 26ca54d

File tree

1 file changed

+22
-4
lines changed

1 file changed

+22
-4
lines changed

.github/workflows/deploy.yml

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
1-
name: Build on Push to Main
1+
name: Deploy to GitHub Pages
22

33
on:
44
push:
55
branches: [main]
66

7+
permissions:
8+
contents: read
9+
pages: write
10+
id-token: write
11+
712
jobs:
813
build:
914
runs-on: ubuntu-latest
15+
1016
steps:
1117
- uses: actions/checkout@v4
1218

@@ -18,8 +24,20 @@ jobs:
1824
- name: Install Trunk
1925
uses: jetli/trunk-action@v0.5.0
2026
with:
21-
version: 'latest'
27+
version: latest
2228

23-
- name: Build Project
24-
run: trunk build --release --public-url /
29+
- name: Build
30+
run: trunk build --release --public-url /${{ github.repository }}/
31+
32+
- name: Upload Pages artifact
33+
uses: actions/upload-pages-artifact@v3
34+
with:
35+
path: dist
2536

37+
deploy:
38+
needs: build
39+
runs-on: ubuntu-latest
40+
41+
steps:
42+
- name: Deploy to GitHub Pages
43+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)