Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I'm a single developer trying to use Git (I'm told it's much better than SVN) to keep track of my XNA project. Would I copy my project into a bare repository and then add the files? If so, do I need all of them? Also, what do I do with my Content project and files - will Git copy them over each commit/push, massively increasing repo size?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

With Git you can supply a .gitignore file which can contain wildcards for files that dont need to be stored in the repository. As per your idea of creating the repository and then adding the files, that would definitely work. Just be sure to read up on how git works as it seems a bit backwards in comparison to svn. Look for a program called Git extensions which is essentially a gui wrapper for git that will make things a bit easier.

Git is not so good at binary files so you'll have to include your output xnb files in the .gitignore so that they aren't constantly being updated but your source content should only have to be updated when you actually make changes.

share|improve this answer
    
What about all the other rubbish (all the .pdb files, .suo, etc)? They're autogenerated but do I need them? –  William Osborne Mar 8 '13 at 19:43
    
Here is a link to the conversation on a different thread: stackoverflow.com/questions/2143956/… In addition to that simply add the wildcards for the binary content files. –  RobCurr Mar 8 '13 at 20:08
    
Cheers, that worked fine apart from an error saying it couldn't copy the xnb files which fixed itself on restart. –  William Osborne Mar 9 '13 at 8:30

Your Answer

 
discard

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.