blob: d66de24afa10fe603772acba7d794a57424c4f2a [file]
#!/bin/bash
# SPDX-License-Identifier: GPL-2.0
# Copyright (c) 2024-2026 Krzysztof Kozlowski <krzk@kernel.org>
#
# Installation:
# 1. Copy to .git/hooks/post-merge
# 2. Adjust paths and LINUS_MASTER_REF
#
TOOLS_DIR="__REPLACE__TOOLS__"
LINUS_MASTER_REF="linus/master"
echo -n "[Checking merge] "
git --no-pager log --format="%C(auto) %h %s" -n1
echo "[b4] "
${TOOLS_DIR}verify_b4.sh >&2
test $? -eq 0 && echo "OK"
echo
echo "[Signed-off-by] "
${TOOLS_DIR}verify_signedoff.sh "HEAD@{1}..HEAD"
test $? -eq 0 && echo "OK"
echo
echo "[Fixes] "
${TOOLS_DIR}verify_fixes.sh "$LINUS_MASTER_REF" "HEAD@{1}..HEAD"
test $? -eq 0 && echo "OK"
echo
echo "[Sanity] "
${TOOLS_DIR}verify_sanity.sh HEAD^1 HEAD^2
test $? -eq 0 && echo "OK"
echo
exit 0