-
Notifications
You must be signed in to change notification settings - Fork 0
/
justfile
executable file
·47 lines (35 loc) · 961 Bytes
/
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
45
46
47
#!/usr/bin/env -S just --justfile
alias d := dev
alias r := run
alias f := fmt
alias l := lint
alias t := test
# List available commands.
_default:
just --list --unsorted
# Develop the app.
dev:
cargo watch -x 'clippy --locked --all-targets --all-features'
# Develop the app.
run:
touch qml/qml.qrc && cargo run
# Format the codebase.
fmt:
cargo fmt --all -- --config-path ~/.config/rustfmt/rustfmt.toml
# Check if the codebase is properly formatted.
fmt-check:
cargo fmt --all -- --check
# Lint the codebase.
lint:
cargo clippy --locked --all-targets --all-features
# Test the codebase.
test:
cargo test run --all-targets
udeps:
cargo +nightly udeps --all-targets
fix:
cargo fix --all-targets --allow-no-vcs
# Tasks to make the code base comply with the rules. Mostly used in git hooks.
comply: fmt lint test
# Check if the repository complies with the rules and is ready to be pushed.
check: fmt-check lint test