Can I set up git so that it auto pulls or detects changes automatically and deploys? Like heroku, I’d like to set up git publishing on our own web server so that when a user pushes to github or bitbucket, the web server will detect the pushed code change and automatically pull the code.
As a bonus, it would be nice to run some post build batch files or scripts in the process too.
I figure that I could do this with a Jenkins server, but are there any other better ways?
It’s really easy to setup Jenkins to do this. This Ray Wenderlich tutorial has a quick and easy Jenkins setup to check a git repo. http://www.raywenderlich.com/22590/beginning-automated-testing-with-xcode-part-12 (Just skip to the Jenkins part). Once Jenkins is all setup just add in an Execute Shell to run whatever scripts you need. You can have it setup in about 15 min.