#!/usr/bin/env bash
#/ Usage: bin/fmt
#/ Description: Formats and lints the code
source bin/helpers/_utils.sh
set_source_and_root_dir
ensure_virtual_env

if [[ "$1" == "--check" ]]; then
  ruff format --check .
else
  ruff format .
fi