#!/usr/bin/env bash # sh-cherrypick commit-msg: SECONDARY reject backstop. # # commit-msg does NOT fire on a clean `git cherry-pick` auto-commit (that path is caught by # prepare-commit-msg + post-commit); it does fire on the `git commit`-backed path such as # `git cherry-pick --continue`. On that path prepare-commit-msg already runs first and blocks, # so this hook is defense-in-depth against git versions/config where prepare-commit-msg is # bypassed. Shares the exact same guard logic. # # Fail-safe: the only non-zero exit is the deliberate reject block; normal commits are no-ops. set -uo pipefail # shellcheck source=_reject_guard.sh . "$(dirname "$0")/_reject_guard.sh" sh_cherrypick_reject_guard "${1:-}" || exit 1 exit 0