-
Notifications
You must be signed in to change notification settings - Fork 0
/
.justfile
44 lines (35 loc) · 1.28 KB
/
.justfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# SPDX-FileCopyrightText: The audio-viz authors
# SPDX-License-Identifier: CC0-1.0
# just manual: https://github.com/casey/just/#readme
_default:
@just --list
# Format source code
fmt:
cargo fmt --all
# Run clippy with various feature combinations
clippy:
cargo clippy --locked --workspace --all-targets --no-default-features
cargo clippy --locked --workspace --all-targets --no-default-features --features all-controllers
cargo clippy --locked --workspace --no-deps --all-targets --all-features -- -D warnings --cap-lints warn
# Run cargo check for the WASM target with default features enabled
check-wasm:
cargo check --locked --workspace --target wasm32-unknown-unknown
# Run unit tests
test:
RUST_BACKTRACE=1 cargo test --locked --all-features -- --nocapture
# Set up (and update) tooling
setup:
# Ignore rustup failures, because not everyone might use it
rustup self update || true
# cargo-edit is needed for `cargo upgrade`
cargo install cargo-edit just
pip install -U pre-commit
#pre-commit install --hook-type commit-msg --hook-type pre-commit
# Upgrade (and update) dependencies
upgrade: setup
pre-commit autoupdate
cargo upgrade --incompatible --pinned
cargo update
# Run pre-commit hooks
pre-commit:
pre-commit run --all-files