GitMerge for Unity is a free, open source Unity Editor tool that allows you to merge scene and prefab files. This solves the main problem you currently get when using Git to work with Unity.
Unity offers a few solutions for collaborative teamwork. These do not necessarily stick to the standard you're used to. So... why not use Git?
You'll have to take these two things into account in order to get started:
GitMerge for Unity is licensed under the GPL2.0 license.
The recommended way to install GitMerge for Unity is to copy the git url and paste it into the package manager.
How to add a package via git url
Alternatively, just clone the repository into your Assets Folder.
GitMerge for Unity comes as an opt-in merge tool. It is not integrated into Git as an automatic merge tool since merging scenes and prefabs is something you'd usually not want to have done automatically.
First off, you create your merge conflict the way you usually do. Once you're in Git's MERGING state, open the GitMerge window in Unity (Window → GitMerge). Then, drag the scene or prefab you want to merge and drop it into the big box.
This is what a scene merge situation can look like.
The BoxCollider component of the "Cube" GameObject has been automatically merged to the default setting ("keep it").
The user has decided to use "their" version of Transform.LocalPosition, but "our" version of Rigidbody.Interpolate and BoxCollider.IsTrigger.
The other two conflicts have not been addressed yet.
The tool will find the differences between the "our" and "their" version of the scene/prefab. You will get a list of so called "MergeActions" in the tool window. Each MergeAction solves one point of conflict between the two scenes.
To do solve the conflict bit by bit, you will be offered two to three options for each MergeAction:
You can continue to edit the scene in a normal way during merging. It is not recommended to delete GameObjects that might be part of a MergeAction though. Consider merging first, and apply changes to the GameObject hierarchy afterwards for a new commit.
When all MergeActions are flagged as merged, you can click on "Apply merge".
The scene will be saved and marked as merged for git. Since there could be more merge conflicts,
the button will not automatically create a commit.
You'll have to commit your merge manually at some later point.
GitMerge for Unity is an open source tool that is being actively developed.
You can head over to the project page,
check out issues, fork, and make pull requests.
If you find a bug or something to improve, but cannot fix/implement it yourself, feel free to tell me about it.
To see what's up next, have a look at the project's issue page.