Version conflict reason:
If a, b two users are in version number 100, updated kingtuns.txt This file, a user after the modification is completed to submit kingtuns.txt to the server, this time the submission is successful, this time Kingtuns.txt file version number has become 101. At the same time, the B user in the version number 100 of the Kingtuns.txt file for modification, when the modification is completed and submitted to the server, because it is not in the current version of the latest 101 changes, so that the submission failed.
version conflict behavior:
When a conflict occurs, Subversion saves all the target file versions in the current working directory [the last updated version, the currently obtained version (that is, the version that was submitted by someone else), the version of your update, the target file].
Suppose the filename is kingtuns.txt
The corresponding file names are:
Kingtuns.txt.r101
kingtuns.txt.r102
Kingtuns.txt.mine
Kingtuns.txt. Also marks changes from different users in the destination file.
version conflict Resolution:
Scene:
1, now A, b two users have updated Kingtuns.txt files to local.
2, the original document contents are as follows:
3. A user to modify the file, add content "A user modified content" completed after submission to the server
4, B users modify the file, add content "B User modified content" completed after submission to the server
b When the user submits updates to the server, the prompts are as follows:
b When a user submits a file to the server, it prompts for a version expiration: You should first update the version from the version library, then resolve the conflict , perform the svn resolved (Resolve) after the conflict is resolved, and then check in to the version library. After the conflict is resolved, you need to use svn resolved (workaround) to tell the Subversion conflict resolution to commit the update.
There are three options for resolving conflicts :
A, discard your own updates, use svn revert (rollback), and then submit. In this way you don't need to use svn resolved (workaround)
B, discard their own updates, use other people's updates. Overwrite the target file with the latest obtained version, execute resolved filename and submit (select File-right Key-resolve).
C, manual resolution: When the conflict occurs, by communicating with other users, manually update the target file. Then execute resolved filename to dissolve the conflict , and finally commit.
The resolution steps are as follows:
1, in the current directory to perform the "Update" (update) operation
2, on the conflicting files (selected Files--right-click menu-tortoisesvn-edit Conflicts ( conflict resolution)), the following window appears
The theirs window is the current latest version on the server
The mine window is a locally modified version
The merged window is displayed for the merged file contents
3, if you want to use the server version, in the theirs window to select the difference content, right, select the use of the text block (using this chunk).
Similarly, if you want to use the local version, after negotiation, right-click in the Mine window and select Use this text block (using this chunk).
4, after the completion of the modification, save kingtuns.txt file content.
5, in the B user's Conflict directory, select the file--right menu-tortoisesvn-resolved (solve). A list of conflicting files is listed, and if confirmation is resolved, click OK.
6. Conflict Resolution
7, the resolution of the conflict after the submission of documents.
How to reduce the complexity of conflict Resolution:
1, when the document is edited, submit as soon as possible, frequent submission/update can reduce the probability of conflict occurrence, and the complexity of resolving conflicts when it occurs.
2, in the submission, write a clear message, easy to find the reasons for user updates, after all, over time, the original reason for the update may be forgotten
3, develop good habits of use, the use of SVN every time is first submitted, and then updated. When you open the door every morning, get the latest version from the version library first. Documents that have already been edited must be submitted to the version library before leaving work every day.