#!/bin/sh
set -eu

if ! command -v pwsh >/dev/null 2>&1; then
  echo "TinyQuant pre-commit: pwsh is required but was not found."
  exit 1
fi

repo_root="$(git rev-parse --show-toplevel)"
cd "$repo_root"

exec pwsh -NoLogo -NoProfile -ExecutionPolicy Bypass -File ./scripts/pre-commit.ps1
