File tree Expand file tree Collapse file tree 1 file changed +24
-6
lines changed Expand file tree Collapse file tree 1 file changed +24
-6
lines changed Original file line number Diff line number Diff line change 7
7
release :
8
8
types : [published]
9
9
10
+ permissions :
11
+ contents : write
12
+ pages : write
13
+ id-token : write
14
+
10
15
env :
11
16
CARGO_UNSTABLE_EDITION2024 : true
12
17
RUSTUP_TOOLCHAIN : nightly
15
20
build-and-publish :
16
21
name : Build and publish
17
22
runs-on : ubuntu-latest
23
+ permissions :
24
+ contents : write
25
+ pages : write
26
+ id-token : write
18
27
steps :
19
28
- uses : actions/checkout@v3
20
29
with :
@@ -78,19 +87,26 @@ jobs:
78
87
command : doc
79
88
args : --no-deps --all-features
80
89
90
+ - name : Setup Pages
91
+ uses : actions/configure-pages@v4
92
+
93
+ - name : Upload artifact
94
+ uses : actions/upload-pages-artifact@v3
95
+ with :
96
+ path : ' ./target/doc'
97
+
81
98
- name : Deploy to GitHub Pages
82
- if : env.GITHUB_TOKEN != ''
83
- uses : peaceiris/ actions-gh- pages@v3
99
+ id : deployment
100
+ uses : actions/deploy- pages@v4
84
101
with :
85
- github_token : ${{ secrets.GITHUB_TOKEN }}
86
- publish_dir : ./target/doc
87
- env :
88
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
102
+ token : ${{ secrets.GITHUB_TOKEN }}
89
103
90
104
build-binaries :
91
105
name : Build binaries for ${{ matrix.os }}
92
106
runs-on : ${{ matrix.os }}
93
107
needs : build-and-publish
108
+ permissions :
109
+ contents : write
94
110
strategy :
95
111
matrix :
96
112
include :
@@ -172,6 +188,8 @@ jobs:
172
188
name : Create GitHub Release
173
189
runs-on : ubuntu-latest
174
190
needs : build-binaries
191
+ permissions :
192
+ contents : write
175
193
if : github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
176
194
steps :
177
195
- uses : actions/checkout@v3
You can’t perform that action at this time.
0 commit comments