forked from PolymeshAssociation/Polymesh
-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (27 loc) · 839 Bytes
/
docs.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
name: Publish docs
on:
push:
branches:
- master
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: nightly
target: wasm32-unknown-unknown
override: true
default: true
- name: Build docs
run: BUILD_DUMMY_WASM_BINARY=true cargo doc --no-deps --workspace --release --verbose
- name: Add index file
run: echo "<html lang='en'><head><meta http-equiv='refresh' content='0; URL=./polymesh/index.html'></head></html>" > ./target/doc/index.html
- name: Publish to Cloudflare workers
uses: cloudflare/wrangler-action@1.1.0
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
env:
CF_ACCOUNT_ID: ${{ secrets.CF_ACCOUNT_ID }}