Add Support for the Godot Engine #332
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
pull_request: | |
push: | |
branches: | |
- 'master' | |
tags: | |
- '*' | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
label: | |
- WebAssembly Unknown | |
- WebAssembly WASI | |
include: | |
- label: WebAssembly Unknown | |
target: wasm32-unknown-unknown | |
os: ubuntu-latest | |
install_target: true | |
- label: WebAssembly WASI | |
target: wasm32-wasi | |
os: ubuntu-latest | |
install_target: true | |
steps: | |
- name: Checkout Commit | |
uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: hecrj/setup-rust-action@v2 | |
with: | |
rust-version: ${{ matrix.toolchain || 'stable' }} | |
- name: Install Target | |
if: matrix.install_target != '' | |
run: rustup target add ${{ matrix.target }} | |
- name: Build (No Default Features) | |
run: | | |
cargo build --no-default-features --target ${{ matrix.target }} | |
- name: Build (Default Features) | |
run: | | |
cargo build --target ${{ matrix.target }} | |
- name: Build (All Features) | |
run: | | |
cargo build --all-features --target ${{ matrix.target }} | |
- name: Test (Target, All Features) | |
run: | | |
cargo test --all-features | |
# Test on the host to also run the doc tests | |
- name: Test (Host, All Features) | |
run: | | |
cargo test --target x86_64-unknown-linux-gnu --all-features | |
clippy: | |
name: Check clippy lints | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Commit | |
uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: hecrj/setup-rust-action@v2 | |
with: | |
components: clippy | |
- name: Run Clippy | |
run: cargo clippy --all-features | |
format: | |
name: Check formatting | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Commit | |
uses: actions/checkout@v4 | |
- name: Install Rust | |
uses: hecrj/setup-rust-action@v2 | |
with: | |
components: rustfmt | |
- name: Run cargo fmt | |
run: cargo fmt -- --check || true |