chore: update RED4ext.SDK (#38) #288
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: CI | |
on: | |
push: | |
branches: ["master"] | |
pull_request: | |
env: | |
CARGO_INCREMENTAL: 0 # Incremental not supported by our caching | |
CARGO_TERM_COLOR: always # GH action logs support terminal colors | |
CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse # New format as of 2023-03-09 | |
jobs: | |
test: | |
name: Run test | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> $env:GITHUB_ENV | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo test --all-features | |
format: | |
name: Run format | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> $env:GITHUB_ENV | |
- uses: dtolnay/rust-toolchain@nightly | |
with: | |
components: rustfmt | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo fmt --all --check | |
lint: | |
name: Run clippy | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> $env:GITHUB_ENV | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo clippy -- -Dwarnings | |
build: | |
name: Build an example | |
runs-on: windows-2019 | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: true | |
- run: echo "LIBCLANG_PATH=$((gcm clang).source -replace "clang.exe")" >> $env:GITHUB_ENV | |
- uses: dtolnay/rust-toolchain@nightly | |
- uses: Swatinem/rust-cache@v2 | |
- run: | | |
cargo build --manifest-path .\examples\hello_world\Cargo.toml --release | |
cargo build --manifest-path .\examples\menu_button\Cargo.toml --release | |
cargo build --manifest-path .\examples\player_info\Cargo.toml --release | |
- uses: actions/upload-artifact@v3 | |
with: | |
path: | | |
examples/hello_world/target/release/hello_world.dll | |
examples/menu_button/target/release/menu_button.dll | |
examples/player_info/target/release/player_info.dll |