Unity offers an Asset ServerLegacy - An Asset and version control system with a graphical user interface integrated into Unity. Enables team members to work together on a Project on different computers. More info
See in Glossary add-on product for easy integrated versioning of your projects and you can also use PerforceA version control system for file change management. More info
See in Glossary and PlasticSCM as external tools (see Version Control Integration for further details). If you for some reason are not able use these systems, it is possible to store your project in any other version controlA system for managing file changes. You can use Unity in conjunction with most common version control tools, including Perforce, Git, Mercurial and PlasticSCM. More info
See in Glossary system, such as Subversion or Bazaar. This requires some initial manual setup of your project.
Before checking your project in, you have to tell Unity to modify the project structure slightly to make it compatible with storing assets in an external version control system. This is done by selecting Edit->Project Settings->Editor in the application menu and enabling External Version Control support by selecting Visible Meta Files in the dropdown for Version Control. This will show a text file for every asset in the Assets
directory containing the necessary bookkeeping information required by Unity. The files will have a .meta
file extension with the first part being the full file name of the asset it is associated with. Moving and renaming assets within Unity should also update the relevant .meta
files. However, if you move or rename assets from an external tool, make sure to syncronize the relevant .meta
files as well.
When checking the project into a version control system, you should add the Assets
, Packages
and the ProjectSettings
directories to the system. The Library
directory should be completely ignored - when using .meta files, it’s only a local cache of imported assets.
When creating new assets, make sure both the asset itself and the associated .meta
file is added to version control.
First, let’s assume that we have a subversion repository at svn://my.svn.server.com/
and want to create a project at svn://my.svn.server.com/MyUnityProject
.
Then follow these steps to create the initial import in the system:
InitialUnityProject
. You can add any initial assets here or add them later on.Library
directory inside your project directory.svn import -m"Initial project import" InitialUnityProject svn://my.svn.server.com/MyUnityProject
If successful, the project should now be imported into subversion and you can delete the InitialUnityProject
directory if you wish.svn co svn://my.svn.server.com/MyUnityProject
and check that the Assets
, Packages
and ProjectSettings
directory are versioned.Library
directory in step 4 above.Library
directory:
svn propedit svn:ignore MyUnityProject/
Subversion will open a text editor. Add the Library directory.svn ci -m"Finishing project import" MyUnityProject
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Is something described here not working as you expect it to? It might be a Known Issue. Please check with the Issue Tracker at issuetracker.unity3d.com.
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thanks for helping to make the Unity documentation better!