Skip to content

Commit 8b3ebdc

Browse files
committed
port CI to GHA
1 parent 204a85b commit 8b3ebdc

File tree

2 files changed

+48
-10
lines changed

2 files changed

+48
-10
lines changed

.github/workflows/deploy.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Deploy
2+
on:
3+
push:
4+
branches: [ master ]
5+
pull_request:
6+
branches: [ master ]
7+
8+
jobs:
9+
build:
10+
# we run this part also in PRs, to ensure that building the book works
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v3
14+
with:
15+
fetch-depth: 0
16+
- name: Install mdbook
17+
run: |
18+
mkdir mdbook
19+
curl -Lf https://github.com/rust-lang/mdBook/releases/download/v0.4.34/mdbook-v0.4.34-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=./mdbook
20+
echo `pwd`/mdbook >> $GITHUB_PATH
21+
- name: Generate Book
22+
run: |
23+
cd reference
24+
mdbook build
25+
mdbook test
26+
- name: Upload Artifact
27+
uses: actions/upload-pages-artifact@v1.0.8
28+
with:
29+
path: reference/book
30+
31+
deploy:
32+
needs: build
33+
34+
permissions:
35+
pages: write
36+
id-token: write
37+
38+
environment:
39+
name: github-pages
40+
url: ${{ steps.deployment.outputs.page_url }}
41+
42+
# only do this part on an actual push
43+
if: github.event_name == 'push'
44+
45+
runs-on: ubuntu-latest
46+
steps:
47+
- id: deployment
48+
uses: actions/deploy-pages@v2.0.0

.travis.yml

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)