Skip to content

Commit

Permalink
Merge branch 'dev' into split-crates
Browse files Browse the repository at this point in the history
  • Loading branch information
melody-rs authored Oct 19, 2023
2 parents 9f78c0e + 8df8758 commit 83af835
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 3 deletions.
44 changes: 43 additions & 1 deletion .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,26 @@ jobs:
uses: Swatinem/rust-cache@v2
- run: cargo check --all-features --jobs 1

check-wasm32:
name: Check wasm32
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install libraries
run: |
sudo apt update
sudo apt install libgtk-3-dev libatk1.0-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libspeechd-dev libxkbcommon-dev libssl-dev libasound2-dev clang mold -y
- uses: dtolnay/rust-toolchain@nightly
with:
toolchain: nightly-2023-09-12
targets: wasm32-unknown-unknown
components: rust-src
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- run: cargo check --jobs 1 --target wasm32-unknown-unknown -Z build-std=std,panic_abort

test:
name: Test Suite
runs-on: ubuntu-latest
Expand All @@ -38,6 +58,28 @@ jobs:
uses: Swatinem/rust-cache@v2
- run: cargo test --lib --jobs 1

trunk:
name: Trunk
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Install libraries
run: |
sudo apt update
sudo apt install libgtk-3-dev libatk1.0-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libspeechd-dev libxkbcommon-dev libssl-dev libasound2-dev clang mold -y
- uses: dtolnay/rust-toolchain@nightly
with:
toolchain: nightly-2023-09-12
targets: wasm32-unknown-unknown
components: rust-src
- name: Download and install Trunk binary
run: wget -qO- https://github.com/thedodd/trunk/releases/download/v0.17.5/trunk-x86_64-unknown-linux-gnu.tar.gz | tar -xzf-
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- run: ./trunk build

fmt:
name: Rustfmt
runs-on: ubuntu-latest
Expand Down Expand Up @@ -74,4 +116,4 @@ jobs:
components: clippy
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- run: cargo clippy --jobs 1 -- # -D warnings
- run: cargo clippy --jobs 1 -- # -D warnings
4 changes: 2 additions & 2 deletions check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
set -eux

cargo check --workspace --all-targets
# cargo check --workspace --all-features --lib --target wasm32-unknown-unknown
cargo check --workspace --target wasm32-unknown-unknown -Z build-std=std,panic_abort
cargo fmt --all -- --check
cargo clippy --workspace --all-targets --all-features -- -D warnings -W clippy::all
cargo test --workspace --all-targets --all-features
cargo test --workspace --doc
# trunk build
trunk build

0 comments on commit 83af835

Please sign in to comment.