#!/bin/sh
FILES_AFFECTED=$(git diff --name-only --diff-filter=AMR|xargs)
if [ ! -z "${FILES_AFFECTED}" ]; then
  scripts/insert.py --presubmit ${FILES_AFFECTED:?}
fi
cargo +nightly fmt -- --check
cargo test --features=float-as-double
