X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=topgit.git;a=blobdiff_plain;f=tg.sh;h=9d08d636af97b6b4f3ad574b7fa486cca119f7aa;hp=91c374a0978a8a7bcb447130a032f264b14d5c91;hb=a6b2d9185652d7a87af465346d548b535a739809;hpb=74e952f9771c8116100451a7eb177c663cf9c43b diff --git a/tg.sh b/tg.sh index 91c374a..9d08d63 100644 --- a/tg.sh +++ b/tg.sh @@ -54,6 +54,8 @@ setup_hook() else hook_call="exec $hook_call" fi + # Don't call hook if tg is not installed + hook_call="if which \"$tg\" > /dev/null; then $hook_call; fi" # Insert call into the hook { echo "#!/bin/sh"