File tree 1 file changed +65
-0
lines changed
1 file changed +65
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Deploy Website to GitHub Pages
2
+
3
+ on :
4
+ # Runs on pushes targeting the `main` branch. Change this to `master` if you're
5
+ # using the `master` branch as the default branch.
6
+ push :
7
+ branches : [main]
8
+ # Allows you to run this workflow manually from the Actions tab
9
+ workflow_dispatch :
10
+
11
+ # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
12
+ permissions :
13
+ contents : read
14
+ pages : write
15
+ id-token : write
16
+
17
+ # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
18
+ # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
19
+ concurrency :
20
+ group : pages
21
+ cancel-in-progress : false
22
+
23
+ jobs :
24
+ # Build job
25
+ build :
26
+ runs-on : ubuntu-latest
27
+ defaults :
28
+ run :
29
+ working-directory : src/webpage/
30
+ steps :
31
+ - name : Checkout
32
+ uses : actions/checkout@v4
33
+ with :
34
+ fetch-depth : 0 # Not needed if lastUpdated is not enabled
35
+ - name : Setup Node
36
+ uses : actions/setup-node@v4
37
+ with :
38
+ node-version : 20
39
+ cache : npm
40
+ cache-dependency-path : src/webpage/package-lock.json
41
+ - name : Setup Pages
42
+ uses : actions/configure-pages@v4
43
+ - name : Install dependencies
44
+ run : npm ci
45
+ - name : Build with VitePress
46
+ run : |
47
+ npm run docs:build
48
+ touch .vitepress/dist/.nojekyll
49
+ - name : Upload artifact
50
+ uses : actions/upload-pages-artifact@v3
51
+ with :
52
+ path : src/webpage/.vitepress/dist/
53
+
54
+ # Deployment job
55
+ deploy :
56
+ environment :
57
+ name : github-pages
58
+ url : ${{ steps.deployment.outputs.page_url }}
59
+ needs : build
60
+ runs-on : ubuntu-latest
61
+ name : Deploy
62
+ steps :
63
+ - name : Deploy to GitHub Pages
64
+ id : deployment
65
+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments