File tree Expand file tree Collapse file tree 1 file changed +8
-18
lines changed Expand file tree Collapse file tree 1 file changed +8
-18
lines changed Original file line number Diff line number Diff line change 1010 workflow_dispatch :
1111
1212permissions :
13- contents : read
13+ contents : write # to write the built page to the branch
1414
1515concurrency :
1616 group : pages
1717 cancel-in-progress : false
1818
1919jobs :
20+
2021 build :
2122 runs-on : ubuntu-latest
2223 steps :
@@ -27,24 +28,13 @@ jobs:
2728 with :
2829 node-version : 22
2930 cache : npm
31+
3032 - uses : actions/configure-pages@v4
33+
3134 - run : npm ci
3235 - run : npm run build
33- - uses : actions/upload-pages-artifact@v3
36+
37+ - uses : rossjrw/pr-preview-action@v1
38+ if : ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/main' }}
3439 with :
35- path : .vitepress/dist
36-
37- deploy :
38- if : ${{ github.event_name != 'pull_request' && github.ref == 'refs/heads/main' }}
39- permissions :
40- pages : write
41- id-token : write
42- environment :
43- name : github-pages
44- url : ${{ steps.deployment.outputs.page_url }}
45- needs : build
46- runs-on : ubuntu-latest
47- name : deploy
48- steps :
49- - id : deployment
50- uses : actions/deploy-pages@v4
40+ source-dir : .vitepress/dist
You can’t perform that action at this time.
0 commit comments