knit := "knit" cargo := "cargo" # Show this help message default: @just --list # Build every tool all: {{ knit }} all # Build one or more tools build +targets: {{ knit }} {{ "bin/" + replace(targets, " ", " bin/") }} # Build and run a tool run target *args: @{{ knit }} bin/{{ target }} && ./bin/{{ target }} {{ args }} # Build and copy tools to ~/.local/bin deploy +targets: {{ knit }} {{ "deploy/" + replace(targets, " ", " deploy/") }} # Run all test suites test: {{ cargo }} test --workspace cd pracomer && zig build test cd wrd && go test ./... python3 -m unittest discover -s mpd/tests -v # Run `cargo clippy` over the workspace clippy: {{ cargo }} clippy --workspace --all-targets # Format the Rust workspace with rustfmt rustfmt: {{ cargo }} fmt --all # Update `requirements.txt` lockfile from requirements.in pip-update: {{ knit }} .venv-stamp .venv/bin/pip install --quiet pip-tools .venv/bin/pip-compile --generate-hashes --strip-extras requirements.in -o requirements.txt # Update `Cargo.lock` lockfile cargo-lockfile: {{ cargo }} generate-lockfile # Remove build artifacts and caches clean: {{ cargo }} clean for dir in pmn pracomer speediness; do rm -rf "$dir"/zig-out "$dir"/.zig-cache; done for dir in hue; do rm -rf "$dir"/vendor; done find bin -type f -delete rm -rf .venv .knit .venv-stamp