Re: [PATCH] Add a sample hook which saves push certs as notes

2017-12-02 Thread Junio C Hamano
Todd Zullinger writes: > (I also noticed the tests which use $GIT_PUSH_CERT, like t5534, use > 'cat-file blob ...' rather than 'cat-file -p ...'. I don't know if > that's much safer/better than letting cat-file guess the object type > in the hook. The '-p' option is meant for human consumption

Re: [PATCH] Add a sample hook which saves push certs as notes

2017-12-02 Thread Todd Zullinger
Hi Shikher, I'm not familiar with push certs, but I did notice some general issues in the sample hook. I hope they're helpful. Shikher Verma wrote: index 0..b4366e43f --- /dev/null +++ b/templates/hooks--post-receive.sample +#!/bin/sh ... +if test -z GIT_PUSH_CERT ; then +exit 0

[PATCH] Add a sample hook which saves push certs as notes

2017-12-02 Thread Shikher Verma
hooks--post-receive.sample: If push cert is present, add it as a git note to the top most commit of the updated ref. Signed-off-by: Shikher Verma --- templates/hooks--post-receive.sample | 38 1 file changed, 38 insertions(+) create mode 100755 templates/hoo