I am trying to print the repo name
from which the commits are being pushed on to the central repo
in the post-receive script
that is used for mailing git pushes .
I tried adding the following code to a script from
https://github.com/zma/usefulscripts/blob/master/script/post-receive
IN main -
dir=`git rev-parse --show-toplevel`
echo "$dir"
base=`basename "$dir"`
echo "$base"
But it prints nothing when I do a push. can anyone please help me? Thanks