Git – One or Two Repos for Android App and Web Service Backend?

androidgit

I'm wondering what the best practice is for my git repository structure where I have an Android application + a web service backend. In general, I'd like to release these two independently (e.g., perf fixes to the backend with no changes to the front-end), but I am worried that if I keep these in two separate repos I'll lose the ability to see combined app + web service changes (e.g., there's a change in the APIs on the server).

What are other Android developers doing to manage their source code + release process? Should I use one git repo with separate folders or two git repos?

I should note that I'd like to set this up as push-to-deploy — any changes to my master branch will trigger a tag and deploy.

Best Answer

It's two different projects, so use two different repos. It's not hard to have post commit hooks in both. Having multiple projects in the same repo just makes it messier to work on one while you're able to see the other, which leads to multiple copies, which leads to confusion.... if you're using a hosting service like GitHub you can see the changes to all the repos under an Organization (and other services have similar idioms) on one page.