File tree Expand file tree Collapse file tree 1 file changed +61
-0
lines changed Expand file tree Collapse file tree 1 file changed +61
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Deploy VitePress site to Pages
2
+
3
+ on :
4
+ push :
5
+ branches : [main]
6
+ paths :
7
+ - " docs/**"
8
+ - " package.json" # for versioning
9
+
10
+ # leave empty, we just want the button
11
+ workflow_dispatch :
12
+
13
+ # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
14
+ permissions :
15
+ contents : read
16
+ pages : write
17
+ id-token : write
18
+
19
+ # Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
20
+ # However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
21
+ concurrency :
22
+ group : pages
23
+ cancel-in-progress : false
24
+
25
+ jobs :
26
+ build :
27
+ name : Build Docs
28
+ runs-on : ubuntu-latest
29
+ steps :
30
+ - name : Checkout
31
+ uses : actions/checkout@v4
32
+ with :
33
+ fetch-depth : 0
34
+
35
+ - name : Setup Bun
36
+ uses : oven-sh/setup-bun@v1
37
+
38
+ - name : Setup Pages
39
+ uses : actions/configure-pages@v3
40
+ - name : Install dependencies
41
+ run : bun i
42
+ - name : Build with VitePress
43
+ run : |
44
+ bun run docs:build
45
+ touch docs/.vitepress/dist/.nojekyll
46
+ - name : Upload artifact
47
+ uses : actions/upload-pages-artifact@v2
48
+ with :
49
+ path : docs/.vitepress/dist
50
+
51
+ deploy :
52
+ name : Deploy Docs
53
+ environment :
54
+ name : github-pages
55
+ url : ${{ steps.deployment.outputs.page_url }}
56
+ needs : build
57
+ runs-on : ubuntu-latest
58
+ steps :
59
+ - name : Deploy to GitHub Pages
60
+ id : deployment
61
+ uses : actions/deploy-pages@v2
You can’t perform that action at this time.
0 commit comments