File tree Expand file tree Collapse file tree 3 files changed +36
-0
lines changed Expand file tree Collapse file tree 3 files changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Deploy to GitHub Pages
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ branch :
7+ type : choice
8+ description : Which branch to deploy?
9+ required : true
10+ options :
11+ - main
12+
13+ jobs :
14+ deploy :
15+ runs-on : ubuntu-latest
16+ steps :
17+ - uses : actions/checkout@v4
18+ with :
19+ ref : ${{ github.event.inputs.branch }}
20+ - name : Enable pnpm
21+ run : " corepack enable"
22+ - name : Use Node.js 22.x
23+ uses : actions/setup-node@v4
24+ with :
25+ node-version : 22.x
26+ cache : pnpm
27+ - run : pnpm install
28+ - run : npm run build
29+ - run : npm run docs
30+ - name : Deploy
31+ uses : peaceiris/actions-gh-pages@v4
32+ with :
33+ github_token : ${{ secrets.GITHUB_TOKEN }}
34+ publish_dir : docs
Original file line number Diff line number Diff line change 2424 - run : pnpm i -r
2525 - run : npm run build
2626 - run : npm run test
27+ - run : npm run docs
2728 - run : npm pkg delete devDependencies scripts packageManager
2829 - name : Deploy Docs
2930 uses : peaceiris/actions-gh-pages@v4
Original file line number Diff line number Diff line change 2424 },
2525 "scripts" : {
2626 "build" : " peggy --format es test/minimal.peggy && tsc" ,
27+ "docs" : " typedoc" ,
2728 "lint" : " eslint ." ,
2829 "test" : " c8 node --test test/*.test.js"
2930 },
You can’t perform that action at this time.
0 commit comments