-
-
Notifications
You must be signed in to change notification settings - Fork 57
37 lines (31 loc) · 941 Bytes
/
build_ghpages.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
36
37
name: Build GitHub Pages
on:
push:
branches: ["main"]
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@master
with:
fetch-depth: 0
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
target: wasm32-unknown-unknown
profile: minimal
override: true
- run: git branch -D ghpages
continue-on-error: true
- run: git checkout -b ghpages
- run: rm .gitignore
- run: mv .gitignore.ghpages .gitignore
- run: cargo build --lib --target wasm32-unknown-unknown --release
- run: mv ./target/wasm32-unknown-unknown/release/customasm.wasm ./web/customasm.wasm
- run: git config user.name github-actions
- run: git config user.email [email protected]
- run: git add -A
- run: git commit -m "build GitHub Pages"
- run: git push -f origin ghpages