t7505: use SHELL_PATH in hook

The hook doesn't run properly under Solaris /bin/sh. Let's
use the SHELL_PATH the user told us about already instead.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Jeff King 2008-03-12 17:42:43 -04:00 committed by Junio C Hamano
parent 32aedd5496
commit 462f8caf24

View file

@ -25,8 +25,9 @@ export FAKE_EDITOR
HOOKDIR="$(git rev-parse --git-dir)/hooks"
HOOK="$HOOKDIR/prepare-commit-msg"
mkdir -p "$HOOKDIR"
cat > "$HOOK" <<'EOF'
#!/bin/sh
echo "#!$SHELL_PATH" > "$HOOK"
cat >> "$HOOK" <<'EOF'
if test "$2" = commit; then
source=$(git-rev-parse "$3")
else