mirror of
https://github.com/git/git
synced 2024-08-24 18:26:02 +00:00
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:
parent
32aedd5496
commit
462f8caf24
|
@ -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
|
||||
|
|
Loading…
Reference in a new issue