From: Michael Wallner Date: Tue, 16 Sep 2014 16:04:30 +0000 (+0200) Subject: override branch in hook to the currently checked out X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=c4b5e298a72aa303457c54641b75c20808cec06f;p=m6w6%2Fbtr override branch in hook to the currently checked out --- diff --git a/bin/btr-hook b/bin/btr-hook index bd0187b..644d60c 100755 --- a/bin/btr-hook +++ b/bin/btr-hook @@ -29,7 +29,7 @@ git) else echo "#!/bin/bash" fi - echo $(btr-conf-dump) "'$BTR_BINDIR/btr' -qy &" + echo $(btr-conf-dump) 'BTR_BRANCH=$(basename $(git symbolic-ref HEAD))' "'$BTR_BINDIR/btr' -qy &" ) >"$BTR_HOOK_FILE.tmp" && \ chmod +x "$BTR_HOOK_FILE.tmp" && \ mv "$BTR_HOOK_FILE.tmp" "$BTR_HOOK_FILE" && \