File tree Expand file tree Collapse file tree 1 file changed +41
-0
lines changed
Expand file tree Collapse file tree 1 file changed +41
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CD
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+ workflow_dispatch :
8+
9+ jobs :
10+ publish :
11+ name : Publish
12+ runs-on : ubuntu-latest
13+ permissions :
14+ contents : read
15+ deployments : write
16+ steps :
17+ - name : Checkout Source Code
18+ uses : actions/checkout@v4
19+
20+ - name : Setup Rust
21+ uses : dtolnay/rust-toolchain@stable
22+
23+ - name : Setup Rust Cache
24+ uses : Swatinem/rust-cache@v2
25+
26+ - name : Setup Cargo Binstall
27+ uses : cargo-bins/cargo-binstall@main
28+
29+ - name : Install Rust Binaries
30+ run : cargo binstall -y --force mdbook
31+
32+ - name : Build
33+ run : mdbook build
34+
35+ - name : Publish
36+ uses : cloudflare/wrangler-action@v3
37+ with :
38+ apiToken : ${{ secrets.CLOUDFLARE_API_TOKEN }}
39+ accountId : ${{ secrets.CF_ACCOUNT_ID }}
40+ command : pages deploy ./book --project-name=${{ secrets.CLOUDFLARE_PAGES_PROJECT_NAME }} --branch=main
41+ gitHubToken : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments