-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
76 lines (58 loc) · 1.2 KB
/
justfile
File metadata and controls
76 lines (58 loc) · 1.2 KB
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# Default recipe
default: check
# Run all checks
check: fmt-check lint test audit
# Format check
fmt-check:
cargo fmt --check
# Format code
fmt:
cargo fmt
# Run clippy
lint:
cargo clippy -- -D warnings
# Run tests
test:
cargo test
# Run security audit
audit:
cargo audit
# Run cargo-deny
deny:
cargo deny check
# Check for outdated dependencies
outdated:
cargo outdated
# Check for unused dependencies
machete:
cargo machete
# Build release
build:
cargo build --release
# Install locally
install:
cargo install --path .
# Clean build artifacts
clean:
cargo clean
# Run all fixes
fix: fmt
cargo clippy --fix --allow-dirty
# Generate shell completions
completions:
mkdir -p completions
cargo run -- completions bash > completions/mkunit.bash
cargo run -- completions zsh > completions/_mkunit
cargo run -- completions fish > completions/mkunit.fish
# Generate man page
man:
GENERATE_MAN=1 cargo build --release
cp target/release/build/mkunit-*/out/man/mkunit.1 .
# Full CI check
ci: fmt-check lint test audit deny
# Watch for changes and run tests
watch:
cargo watch -x test
# Run with verbose output
run *ARGS:
cargo run -- -v {{ARGS}}