1BINDIR := $(or $(XDG_BIN_HOME),$(XDG_BIN_DIR),$(HOME)/.local/bin)
2
3.PHONY: all check test fmt clippy ci install
4
5all: fmt check test
6
7ci: fmt
8 @cargo check --quiet 2>&1 || true
9 @cargo clippy --quiet -- -D warnings 2>&1 || true
10 @cargo test --quiet 2>&1 | grep -E '(^test |^running|test result|FAILED|error)'
11
12check:
13 @cargo check --quiet
14 @cargo clippy --quiet -- -D warnings
15
16test:
17 @cargo test --quiet
18
19fmt:
20 @cargo fmt
21
22clippy:
23 @cargo clippy --quiet -- -D warnings
24
25install:
26 cargo build --release --quiet
27 install -Dm755 target/release/td "$(BINDIR)/td"