File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 66 pull_request :
77 branches : [ main ]
88
9+ permissions :
10+ contents : read
11+ pages : write
12+ id-token : write
13+
914jobs :
1015 docs :
1116 name : Build Documentation
1217 runs-on : ubuntu-latest
18+ environment :
19+ name : github-pages
20+ url : ${{ steps.deployment.outputs.page_url }}
1321 steps :
1422 - uses : actions/checkout@v4
1523
@@ -28,10 +36,17 @@ jobs:
2836 - name : Build documentation
2937 run : cargo doc --all-features --no-deps
3038
31- - name : Deploy to GitHub Pages
39+ - name : Setup Pages
40+ if : github.ref == 'refs/heads/main'
41+ uses : actions/configure-pages@v3
42+
43+ - name : Upload artifact
3244 if : github.ref == 'refs/heads/main'
33- uses : peaceiris/ actions-gh- pages@v3
45+ uses : actions/upload- pages-artifact@v2
3446 with :
35- github_token : ${{ secrets.GITHUB_TOKEN }}
36- publish_dir : ./target/doc
37- destination_dir : docs
47+ path : ./target/doc
48+
49+ - name : Deploy to GitHub Pages
50+ if : github.ref == 'refs/heads/main'
51+ id : deployment
52+ uses : actions/deploy-pages@v2
You can’t perform that action at this time.
0 commit comments