[Closed] How do I setup Git for an UE4 project?
My question is simple: how can I setup my git repository for an UE4 project? Or, in other words, which files/folders can I safely include in the gitignore file? Are there some tips to make this works flawless? :)
Thank you in advance!
The question has been closed Dec 17 '15 at 07:15 PM by Ben Halliday for the following reason:
The question is answered, right answer was accepted
As a general rule, you should check in all files that are required to make a successful build of your project and cannot be generated from other files. If you or someone else clones your project, they must have everything that is needed for the project - not more not less. Files that are not needed for your project or that can be automatically generated from other files in your project should not be included, because that would be a waste of disk space and just cause conflicts when someone downloads your latest version into their local workspace. The only exception may be documentation, readme files and sample code that may help someone with your project.
Here is a typical folder structure for a code-based project. The files and folders in bold should be included, the rest can (and should) be safely ignored:
**) Make sure you do not discard your raw assets after importing them into the Engine. While they are not strictly required for building the project (the content packages should contain everything needed to run your game), we recommend that you keep them somewhere in version control. If you don't want to keep them in your project's repository (i.e. because you don't want to give them to the public) you should at least maintain some other private repository for yourself so that you do not loose any changes and can always go back to prior versions of textures, static meshes, sounds and so on, if needed.
answered Mar 24 '14 at 05:09 PM
You can commit any of your non binary files safely. The primary issue you will run into is binary files - such as assets, which is a problem for any binary file in VCS that does not have context for the files. By and large the issue exists for all common VCSs but with distributed ones like Mercurial and Git this is a compounded issue.
You should ignore the files created for MSVS, as they are likely to be created on any contributors machine when they run the batch script to generate them. This includes the sdf, opensdf, suo, DotSettings files.
You should also ignore the Saves directory as it wont be of much use to your buddies.
You will also want to ignore the Intermediate directory, as everything in there is generated or copied.
Follow this question
Once you sign in you will be able to subscribe for any updates here