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 have started working on a personal project using Unity with a friend and we've set up our own source control system.

I am aware of the fact that there are many types of files, namely those that are generated locally when you build (for example, Visual Studio files) and those that are specific to your particular machine that should not be added to source control, but I'm not exactly sure what these file types are.

I don't want to exclude any generated files I should be including, such as .meta files.

Would someone be able to list all, or at least all of the common file types that should not be added to version control, specifically for a Unity project?

share|improve this question
add comment

4 Answers

up vote 8 down vote accepted

With the current version of Unity, just check in anything in the Assets folder and ProjectSettings folder. Don't check in anything under Library, or at the top level.

share|improve this answer
add comment

A good reference for this kind of lists is GitHub's gitignore templates. The Unity-specific list is here.

And if you feel that something is missing, make a pull request!

share|improve this answer
add comment

The file type is less important that the file's purpose and origin; as you said, anything that can be generated from the source files under version control (usually) has no business being included in the repository itself.

Similarly, anything user-specific, such as settings or configuration files, should be excluded.

Beyond that it's really up to you and your project.

share|improve this answer
2  
I suppose what I'm asking for really, is a short list of which files in a standard unity project ARE the files that get generated or are user specific. Apart from the files that I manually create I'm fairly ignorant as to which do what and come from where. –  Asher Einhorn Aug 15 '12 at 16:26
    
I see. I edited your question to clarify that, as the Unity bit had been removed by the time I saw it (or I just missed it). –  Josh Petrie Aug 15 '12 at 16:39
add comment

I don't know about unity but you mentioned visual studio. There you can usually exclude the bin and obj folders in the project folders (in some project types, the bin folder also stores assemblies from included projects, but I think this only applies for certain type of web projects).

Also do not check in the ".csproj.user" and ".suo" files. Those two types include user settings. If you check those in, then all user settings will be reflected on the other machines, when you update the source. This is quite annoying, as those settings are not build or project relevant but more to configure the ui, editor etc for each developers individual needs.

share|improve this answer
add comment

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.