Skip to content

Commit

Permalink
setup github action
Browse files Browse the repository at this point in the history
  • Loading branch information
nico committed Sep 21, 2023
1 parent 3fe93e9 commit 072b6ef
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[env]
AUD_IMPORTED_LUA_RS = "imported_lua.rs"
RUST_LOG = "trace"

[build]
rustc-wrapper = "sccache"
#
# [build]
# rustc-wrapper = "sccache"
43 changes: 43 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Rust

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

env:
CARGO_TERM_COLOR: always

jobs:
build:
name: build-test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04, macos-latest, windows-latest]
rust: [stable]
include:
- os: ubuntu-22.04
target: x86_64-unknown-linux-gnu
- os: macos-latest
target: x86_64-apple-darwin
- os: windows-latest
target: x86_64-pc-windows-msvc
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ matrix.rust }}
target: ${{ matrix.target }}
- uses: Swatinem/rust-cache@v2
- run: sudo apt-get update && sudo apt install -y --no-install-recommends libasound2-dev liblua5.4-dev
- if: ${{ matrix.os == 'ubuntu-22.04' }}
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends liblua5.4-dev liblua5.3-dev liblua5.2-dev liblua5.1-0-dev libluajit-5.1-dev
cargo build --features "${{ matrix.lua }}"
- name: build
run: cargo build --verbose
- name: test
run: cargo test --verbose

0 comments on commit 072b6ef

Please sign in to comment.