Skip to content

Commit 1546e97

Browse files
committed
ci: Use GH Actions to deploy docs
1 parent 13d0409 commit 1546e97

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

Diff for: .github/workflows/build.yml

+32
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,18 @@ on:
44
- main
55
workflow_dispatch:
66

7+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
8+
permissions:
9+
contents: read
10+
pages: write
11+
id-token: write
12+
13+
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
14+
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
15+
concurrency:
16+
group: pages
17+
cancel-in-progress: false
18+
719
jobs:
820
build:
921
name: Code quality
@@ -27,3 +39,23 @@ jobs:
2739
with:
2840
token: ${{ secrets.CODECOV_TOKEN }}
2941
verbose: true
42+
- name: Setup Pages
43+
uses: actions/configure-pages@v4
44+
- name: Build with VitePress
45+
run: bun run docs:build
46+
- name: Upload artifact
47+
uses: actions/upload-pages-artifact@v3
48+
with:
49+
path: docs/.vitepress/dist
50+
51+
deploy:
52+
environment:
53+
name: github-pages
54+
url: ${{ steps.deployment.outputs.page_url }}
55+
needs: build
56+
runs-on: ubuntu-latest
57+
name: Deploy
58+
steps:
59+
- name: Deploy to GitHub Pages
60+
id: deployment
61+
uses: actions/deploy-pages@v4

0 commit comments

Comments
 (0)