File tree 1 file changed +28
-13
lines changed
1 file changed +28
-13
lines changed Original file line number Diff line number Diff line change 4
4
push :
5
5
branches :
6
6
- main
7
- # Review gh actions docs if you want to further define triggers, paths, etc
8
- # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#on
9
7
10
8
jobs :
11
- deploy :
12
- name : Deploy to GitHub Pages
9
+ build :
10
+ name : Build Docusaurus
13
11
runs-on : ubuntu-latest
14
12
steps :
15
13
- uses : actions/checkout@v4
16
-
17
14
with :
18
- node-version : 20
15
+ fetch-depth : 0
16
+ - uses : actions/setup-node@v4
17
+ with :
18
+ node-version : 18
19
19
cache : npm
20
20
21
21
- name : Install dependencies
22
22
run : npm ci
23
23
- name : Build website
24
24
run : npm run build
25
25
26
- # Popular action to deploy to GitHub Pages:
27
- # Docs: https://github.com/peaceiris/actions-gh-pages#%EF%B8%8F-docusaurus
28
- - name : Deploy to GitHub Pages
29
- uses : peaceiris/actions-gh-pages@v3
26
+ - name : Upload Build Artifact
27
+ uses : actions/upload-pages-artifact@v3
30
28
with :
31
- github_token : ${{ secrets.GH_TOKEN }}
32
- # Build output to publish to the `gh-pages` branch:
33
- publish_dir : ./build
29
+ path : build
30
+
31
+ deploy :
32
+ name : Deploy to GitHub Pages
33
+ needs : build
34
+
35
+ # Grant GITHUB_TOKEN the permissions required to make a Pages deployment
36
+ permissions :
37
+ pages : write # to deploy to Pages
38
+ id-token : write # to verify the deployment originates from an appropriate source
39
+
40
+ # Deploy to the github-pages environment
41
+ environment :
42
+ name : github-pages
43
+ url : ${{ steps.deployment.outputs.page_url }}
34
44
45
+ runs-on : ubuntu-latest
46
+ steps :
47
+ - name : Deploy to GitHub Pages
48
+ id : deployment
49
+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments