File tree 1 file changed +21
-9
lines changed
1 file changed +21
-9
lines changed Original file line number Diff line number Diff line change 7
7
pull_request :
8
8
9
9
jobs :
10
- deploy :
10
+ build :
11
11
runs-on : ubuntu-24.04
12
- concurrency :
13
- group : ${{ github.workflow }}-${{ github.ref }}
14
12
steps :
15
- - uses : actions/checkout@v2
13
+ - uses : actions/checkout@v4
16
14
17
15
- name : Setup mdBook
18
16
uses : peaceiris/actions-mdbook@v2
21
19
22
20
- run : mdbook build
23
21
24
- - name : Deploy
25
- uses : peaceiris/actions-gh-pages@v3
26
- if : ${{ github.ref == 'refs/heads/main' }}
22
+ - name : Upload static files as artifact
23
+ id : deployment
24
+ uses : actions/upload-pages-artifact@v3
27
25
with :
28
- github_token : ${{ secrets.GITHUB_TOKEN }}
29
- publish_dir : ./book
26
+ path : ./book/
27
+
28
+ deploy :
29
+ environment :
30
+ name : github-pages
31
+ url : ${{ steps.deployment.outputs.page_url }}
32
+ permissions :
33
+ pages : write # to deploy to Pages
34
+ id-token : write # to verify the deployment originates from an appropriate source
35
+ runs-on : ubuntu-latest
36
+ needs : build
37
+ steps :
38
+ - name : Deploy to GitHub Pages
39
+ id : deployment
40
+ if : ${{ github.ref == 'refs/heads/main' }}
41
+ uses : actions/deploy-pages@v4
You can’t perform that action at this time.
0 commit comments