Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Nearly a year ago, I started writing a game. I was just messing around at the time, but now I'm pretty serious about it. As it's grown, it's taken on the responsibilities of a major game engine, as well as the game logic of an actual game.

At some point, I decided I should break the two out, and designate a game and a game engine. I kept this separation in mind as I programmed for about the last 8 months, but I never did actually separate them.

Now I intend to finally move forward with this. The project is all in one git repository right now. I'd like to have two repositories; one for the game engine and one for the game.

I have two concrete questions:

1) How should I split the repository? I'd like to maintain history, so I'm thinking I'll just cp the repository, prune the two, and then check in. Any better ideas?

2) Should I add my game assets (models, images, sounds..) to the game repository, or should I make a third for these? I have quite a few assets, and many are subject to change, so it could create an inconvenient amount of noise.

share|improve this question
This command was about what I was looking for #1: – stephelton Dec 5 '11 at 0:59
up vote 4 down vote accepted

As for #1, git provides some tools to make that very easy to do. For #2, I'd suggest a 2nd repository to keep your history clean and useful. You can pull it into your main working tree easily with git submodules.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.