Normally, when I start up a new application, I'd create a new git repository for it. That's well accepted and plays nice with Github when I want to share my code.
At work, I'm working in a service oriented architecture. One very common pattern is to add some code to two different applications at the same time - perhaps adding a model with a RESTful interface to one and a web frontend for managing it on another. Using separate git repositories has some warts in this case.
Here are what I see as the downsides of doing separate repositories:
- I have to commit twice
- I can't correllate related commits very well
- No single place to go back and trace history - I'd love to be able to bring up all my commits for the day in a single place
- Forgetting to pull one repo or another is a gotcha
On the other hand, I've used perforce a lot and its one giant repository model has lots of warts too. Perforce has features designed to let help you with those, git doesn't.
Has anyone else run into this situation? How did you handle it? What worked well, and what didn't?