2021-02-13 14:36:06 +11:00
|
|
|
name: ci
|
|
|
|
|
|
|
|
on:
|
|
|
|
- push
|
|
|
|
- pull_request
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2021-02-21 05:49:40 +11:00
|
|
|
runs-on: ubuntu-20.04
|
2021-02-13 14:36:06 +11:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
rust:
|
|
|
|
- { toolchain: nightly }
|
|
|
|
steps:
|
|
|
|
- name: Install Apt Dependencies
|
2021-02-21 05:49:40 +11:00
|
|
|
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends build-essential libssl-dev binutils-arm-none-eabi
|
2021-02-13 14:36:06 +11:00
|
|
|
- uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
profile: minimal
|
|
|
|
toolchain: ${{ matrix.rust.toolchain }}
|
|
|
|
default: true
|
|
|
|
- name: Install Rust Source
|
|
|
|
run: rustup component add rust-src
|
2021-02-21 05:49:40 +11:00
|
|
|
- name: Install cargo-make crate
|
2021-02-13 14:36:06 +11:00
|
|
|
uses: actions-rs/install@v0.1
|
|
|
|
with:
|
2021-02-21 05:49:40 +11:00
|
|
|
crate: cargo-make
|
2021-02-13 14:36:06 +11:00
|
|
|
version: latest
|
|
|
|
use-tool-cache: true
|
2021-02-21 05:49:40 +11:00
|
|
|
- name: Install gbafix crate
|
2021-02-13 14:36:06 +11:00
|
|
|
uses: actions-rs/install@v0.1
|
|
|
|
with:
|
2021-02-21 05:49:40 +11:00
|
|
|
crate: gbafix
|
2021-02-13 14:36:06 +11:00
|
|
|
version: latest
|
|
|
|
use-tool-cache: true
|
2021-02-21 05:49:40 +11:00
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Make Test
|
2021-02-13 14:36:06 +11:00
|
|
|
uses: actions-rs/cargo@v1
|
|
|
|
with:
|
|
|
|
toolchain: ${{ matrix.rust.toolchain }}
|
|
|
|
command: make
|
2021-02-21 05:49:40 +11:00
|
|
|
args: test
|
2021-02-13 14:36:06 +11:00
|
|
|
- name: Make Release
|
|
|
|
uses: actions-rs/cargo@v1
|
|
|
|
with:
|
|
|
|
toolchain: ${{ matrix.rust.toolchain }}
|
|
|
|
command: make
|
|
|
|
args: justrelease
|
|
|
|
build-book:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions-rs/toolchain@v1
|
|
|
|
with:
|
|
|
|
profile: minimal
|
|
|
|
toolchain: stable
|
|
|
|
default: true
|
|
|
|
- name: Install mdbook crate
|
|
|
|
uses: actions-rs/install@v0.1
|
|
|
|
with:
|
|
|
|
crate: mdbook
|
|
|
|
version: latest
|
|
|
|
use-tool-cache: true
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Build the book
|
|
|
|
run: cd book && mdbook build
|