Quantcast
Viewing all articles
Browse latest Browse all 3

git Commit Email Notification

I couldn't really find anything that could get me up and running really quickly with git commit emails. In this blog post we provide a git post-receive-email example.  In our case, our server is CentOS.

  1. modify the "description" file on the server in the root of the git repo, so that your project can have a name, and the email subject lines will have that name.
  2. setup the post receive configuration in /etc/gitconfig
  3. In the hooks directory on the server, copy the post-receive.sample to post-receive, and uncomment the post-receive-email script

If in the root of the git repo, issue the following commands to do the above.

echo "Project Name" > description
cat > hooks/post-receive <

Note that the git config command above will change the "config" file in that repo to have a proper email destination.


Viewing all articles
Browse latest Browse all 3

Trending Articles