Skip to content

Commit 5c76879

Browse files
committed
ci: deploy pages with github actions
1 parent 37e8a52 commit 5c76879

2 files changed

Lines changed: 57 additions & 49 deletions

File tree

.github/workflows/pages.yml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Deploy GitBook to GitHub Pages
2+
3+
on:
4+
push:
5+
branches:
6+
- master
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+
build:
20+
runs-on: ubuntu-latest
21+
22+
steps:
23+
- name: Checkout
24+
uses: actions/checkout@v6
25+
26+
- name: Set up Node.js
27+
uses: actions/setup-node@v6
28+
with:
29+
node-version: 22
30+
cache: npm
31+
32+
- name: Install dependencies
33+
run: npm ci
34+
35+
- name: Build GitBook
36+
run: npm run build
37+
38+
- name: Configure GitHub Pages
39+
uses: actions/configure-pages@v5
40+
41+
- name: Upload GitHub Pages artifact
42+
uses: actions/upload-pages-artifact@v4
43+
with:
44+
path: _book
45+
46+
deploy:
47+
runs-on: ubuntu-latest
48+
needs: build
49+
50+
environment:
51+
name: github-pages
52+
url: ${{ steps.deployment.outputs.page_url }}
53+
54+
steps:
55+
- name: Deploy to GitHub Pages
56+
id: deployment
57+
uses: actions/deploy-pages@v4

.travis.yml

Lines changed: 0 additions & 49 deletions
This file was deleted.

0 commit comments

Comments
 (0)