Skip to content

Commit 927dd9f

Browse files
authored
Chore: use ghpages build with actions (#456)
1 parent b908266 commit 927dd9f

File tree

1 file changed

+31
-8
lines changed

1 file changed

+31
-8
lines changed

.github/workflows/GHPages.yml

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,43 @@ name: GHPages
33
on:
44
push:
55
branches: [master]
6+
workflow_dispatch: null
7+
8+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
9+
permissions:
10+
contents: read
11+
pages: write
12+
id-token: write
13+
14+
# Allow one concurrent deployment
15+
concurrency:
16+
group: pages
17+
cancel-in-progress: true
618

719
jobs:
8-
deploy-docs:
20+
deploy:
21+
environment:
22+
name: github-pages
23+
url: ${{ steps.deployment.outputs.page_url }}
924
runs-on: ubuntu-latest
1025
steps:
11-
- uses: actions/checkout@v3
26+
- name: Checkout
27+
uses: actions/checkout@v3
1228
- uses: actions/setup-node@v3
29+
with:
30+
node-version: 18
1331
- name: Install Packages
1432
run: npm ci
1533
- name: Build docs
16-
run: npm run docs:build
17-
- name: Deploy
18-
uses: peaceiris/actions-gh-pages@v3
34+
run: |+
35+
export NODE_OPTIONS=--openssl-legacy-provider
36+
npm run docs:build
37+
- name: Setup Pages
38+
uses: actions/configure-pages@v1
39+
- name: Upload artifact
40+
uses: actions/upload-pages-artifact@v1
1941
with:
20-
github_token: ${{ secrets.GITHUB_TOKEN }}
21-
publish_dir: ./docs/.vuepress/dist
22-
force_orphan: true
42+
path: ./docs/.vuepress/dist
43+
- name: Deploy to GitHub Pages
44+
id: deployment
45+
uses: actions/deploy-pages@v1

0 commit comments

Comments
 (0)