File tree Expand file tree Collapse file tree 1 file changed +21
-4
lines changed Expand file tree Collapse file tree 1 file changed +21
-4
lines changed Original file line number Diff line number Diff line change 1111 name : build and test
1212 runs-on : ubuntu-latest
1313 steps :
14- - uses : actions/checkout@v2
14+ - uses : actions/checkout@v4
1515 - name : Install mdbook
1616 run : |
1717 tag=$(curl -LsSf https://api.github.com/repos/rust-lang/mdBook/releases/latest | jq -r '.tag_name')
2424 run : |
2525 git config --global http.postBuffer 50000000
2626 git config --global https.postBuffer 50000000
27- - uses : rust-lang/simpleinfra/github-actions/static-websites@master
27+ - name : Upload book artifacts
28+ uses : actions/upload-pages-artifact@v3
2829 with :
29- deploy_dir : book
30- github_token : ${{ secrets.GITHUB_TOKEN }}
30+ path : book
3131 if : github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'rust-lang'
32+
33+ # Deploy is run as a separate job as it needs elevated permissions
34+ deploy :
35+ name : deploy
36+ runs-on : ubuntu-latest
37+ needs : test # the `test` job uploads the pages artifact
38+ if : github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'rust-lang'
39+ permissions :
40+ pages : write
41+ id-token : write
42+ environment :
43+ name : github-pages
44+ url : ${{steps.deployment.outputs.page_url}}
45+ steps :
46+ - name : Deploy to GitHub Pages
47+ uses : actions/deploy-pages@v4
48+ id : deployment
You can’t perform that action at this time.
0 commit comments