push automatically on commit
just create a file named
post-commitunder
.git/hooksfill it with
#!/bin/sh
git pushand make it executable
chmod +x .git/hooks/post-commitWritten by Maximilian Weber
Related protips
2 Responses
 
It also needs to be executable.
chmod +x .git/hooks/post-commit
Although tbh I'm not sure this is a great idea.
over 1 year ago
·
 
Thx for the chmod +x hint.
I like to have it for my private repos...
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
 #Git 
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#
 
 
 
