Fix post-receive-email test for USER_EMAIL variable.
[git-central.git] / scripts / functions
1 #!/bin/sh
2
3 function set_branch_name() {
4         branch_name=$(git symbolic-ref --quiet HEAD)
5         if [[ $? -ne 0 ]] ; then
6                 branch_name=""
7         else
8                 branch_name=${branch_name/refs\/heads\//}
9         fi
10 }
11