Debian Codegraph @

Justfile

raw
1 # If you change anything in here, make sure to also adjust the lint CI job!
2 lint:
3 cargo fmt --all -- --check
4 taplo format --check
5 cargo clippy --tests --workspace -- -D warnings
6
7 format:
8 just ensure-command taplo
9 cargo fmt
10 taplo format
11
12
13 # Ensures that one or more required commands are installed
14 ensure-command +command:
15 #!/usr/bin/env bash
16 set -euo pipefail
17
18 read -r -a commands <<< "{{ command }}"
19
20 for cmd in "${commands[@]}"; do
21 if ! command -v "$cmd" > /dev/null 2>&1 ; then
22 printf "Couldn't find required executable '%s'\n" "$cmd" >&2
23 exit 1
24 fi
25 done