Add justfile
This commit is contained in:
parent
ffed778a71
commit
0967ef46a8
2
.gitignore
vendored
2
.gitignore
vendored
@ -12,3 +12,5 @@ Cargo.lock
|
||||
|
||||
# Miscellaneous
|
||||
.DS_Store
|
||||
tarpaulin-report.html
|
||||
*.profraw
|
||||
|
52
justfile
Executable file
52
justfile
Executable file
@ -0,0 +1,52 @@
|
||||
#!/usr/bin/env -S just --justfile
|
||||
|
||||
log := "warn"
|
||||
|
||||
export JUST_LOG := log
|
||||
|
||||
_default:
|
||||
@just --list --unsorted
|
||||
|
||||
# Build all packages
|
||||
[group('build')]
|
||||
build:
|
||||
cargo build --release --workspace
|
||||
|
||||
# Build the specified package
|
||||
[group('build')]
|
||||
build-package PACKAGE:
|
||||
cargo build --release --package={{PACKAGE}}
|
||||
|
||||
# Check test coverage of all packages in the workspace
|
||||
[group('test')]
|
||||
coverage:
|
||||
cargo tarpaulin --workspace --out=Html --exclude=onihime-macros
|
||||
|
||||
# Test all packages
|
||||
[group('test')]
|
||||
test:
|
||||
cargo test --workspace
|
||||
|
||||
# Test the specified package
|
||||
[group('test')]
|
||||
test-package PACKAGE:
|
||||
cargo test --package={{PACKAGE}}
|
||||
|
||||
# Check the formatting of all packages
|
||||
[group('lint')]
|
||||
check-format:
|
||||
cargo fmt --all -- --check
|
||||
|
||||
# Format all packages
|
||||
[group('lint')]
|
||||
format:
|
||||
cargo fmt --all
|
||||
|
||||
# Run clippy checks for all packages
|
||||
[group('lint')]
|
||||
clippy:
|
||||
cargo clippy --no-deps -- -D warnings -W clippy::all
|
||||
|
||||
# Check formatting and run clippy checks for all packages
|
||||
[group('lint')]
|
||||
lint: check-format clippy
|
Loading…
Reference in New Issue
Block a user