File tree Expand file tree Collapse file tree 1 file changed +15
-5
lines changed Expand file tree Collapse file tree 1 file changed +15
-5
lines changed Original file line number Diff line number Diff line change 5
5
pull_request :
6
6
branches : [ main ]
7
7
8
+ # Add explicit permissions - this is crucial!
8
9
permissions :
9
- contents : write
10
+ contents : write
10
11
11
12
jobs :
12
13
build :
13
14
name : Build, Test and Deploy
14
15
runs-on : ubuntu-latest
15
16
steps :
16
- - uses : actions/checkout@v4 # Update to v4
17
+ - uses : actions/checkout@v4
18
+ with :
19
+ fetch-depth : 0 # Important for git history
20
+
17
21
- uses : actions-rs/toolchain@v1
18
22
with :
19
23
toolchain : stable
24
+
20
25
- name : Install mdbook
21
26
run : |
22
27
mkdir bin
23
28
curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.14/mdbook-v0.4.14-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=bin
24
29
echo "$(pwd)/bin" >> $GITHUB_PATH
30
+
25
31
- run : mdbook build
26
- - name : Deploy 🚀
27
- uses : JamesIves/github-pages-deploy-action@v4 # Update to v4
32
+
33
+ - name : Deploy to GitHub Pages
34
+ uses : JamesIves/github-pages-deploy-action@v4
28
35
with :
29
- folder : book # The folder the action should deploy
36
+ folder : book
37
+ branch : gh-pages
38
+ token : ${{ secrets.GITHUB_TOKEN }} # Explicitly use the token
39
+ clean : true # Clean up old files
You can’t perform that action at this time.
0 commit comments