Skip to content

Commit 1d5cf88

Browse files
committed
chore: restore deploy workflow and update actions
1 parent bc004c7 commit 1d5cf88

File tree

1 file changed

+31
-31
lines changed

1 file changed

+31
-31
lines changed

.github/workflows/deploy.yml

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,39 @@
1-
name: Deploy
2-
on:
3-
push:
4-
branches:
5-
- main
6-
7-
jobs:
8-
deploy:
9-
runs-on: ubuntu-latest
10-
permissions:
11-
contents: write # To push a branch
12-
pages: write # To push to a GitHub Pages site
13-
id-token: write # To update the deployment status
14-
steps:
1+
name: Deploy
2+
on:
3+
push:
4+
branches:
5+
- main
6+
7+
jobs:
8+
deploy:
9+
runs-on: ubuntu-latest
10+
permissions:
11+
contents: write # To push a branch
12+
pages: write # To push to a GitHub Pages site
13+
id-token: write # To update the deployment status
14+
steps:
1515
- uses: actions/checkout@v4
1616
with:
1717
fetch-depth: 0
18-
- name: Install latest mdbook
19-
run: |
20-
tag=$(curl 'https://api.github.com/repos/rust-lang/mdbook/releases/latest' | jq -r '.tag_name')
21-
url="https://github.com/rust-lang/mdbook/releases/download/${tag}/mdbook-${tag}-x86_64-unknown-linux-gnu.tar.gz"
22-
mkdir mdbook
23-
curl -sSL $url | tar -xz --directory=./mdbook
24-
echo `pwd`/mdbook >> $GITHUB_PATH
25-
- name: Build Book
26-
run: |
27-
# This assumes your book is in the root of your repository.
28-
# Just add a `cd` here if you need to change to another directory.
29-
mdbook build
18+
- name: Install latest mdbook
19+
run: |
20+
tag=$(curl 'https://api.github.com/repos/rust-lang/mdbook/releases/latest' | jq -r '.tag_name')
21+
url="https://github.com/rust-lang/mdbook/releases/download/${tag}/mdbook-${tag}-x86_64-unknown-linux-gnu.tar.gz"
22+
mkdir mdbook
23+
curl -sSL $url | tar -xz --directory=./mdbook
24+
echo `pwd`/mdbook >> $GITHUB_PATH
25+
- name: Build Book
26+
run: |
27+
# This assumes your book is in the root of your repository.
28+
# Just add a `cd` here if you need to change to another directory.
29+
mdbook build
3030
- name: Setup Pages
31-
uses: actions/configure-pages@v3
31+
uses: actions/configure-pages@v4
3232
- name: Upload artifact
3333
uses: actions/upload-pages-artifact@v2
34-
with:
35-
# Upload entire repository
36-
path: 'book'
34+
with:
35+
# Upload entire repository
36+
path: 'book'
3737
- name: Deploy to GitHub Pages
3838
id: deployment
39-
uses: actions/deploy-pages@v2
39+
uses: actions/deploy-pages@v3

0 commit comments

Comments
 (0)