-
Notifications
You must be signed in to change notification settings - Fork 24
35 lines (33 loc) · 942 Bytes
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
name: Deploy
on:
push:
branches:
- main
env:
CNAME: docs.clamav.net
jobs:
pages:
name: GitHub Pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Install Rust (rustup)
run: rustup update stable --no-self-update && rustup default stable
- name: Install mdBook
run: |
cargo install mdbook
cargo install --git https://github.com/micahsnyder/mdbook-sitemap-generator.git --branch rename-urls-url
- name: Build book
run: |
mdbook build .
mdbook-sitemap-generator -d docs.clamav.net -o book/sitemap.xml
- name: Deploy to GitHub
env:
GITHUB_DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }}
run: |
touch book/.nojekyll
cp googled62299e9391332c4.html book/googled62299e9391332c4.html
echo ${{ env.CNAME }} > book/CNAME
rustc deploy.rs -o /tmp/deploy
cd book
/tmp/deploy