SVN Commit Update

Source: Internet
Author: User

A. Update before submitting
The 1.SVN update principle is to be updated at any time and submitted at any time. When a small function is completed, it can be submitted carefully after compiling and testing itself.
2. If someone changes the SVN file during the modification, the commit may fail. If others and themselves change the same file, then the update will be automatically merged, if you modify the same row, then the merger will create a conflict, this situation needs to contact with the previous developer, two people to resolve the conflict together, after resolving the conflict, two people need to test together to ensure that the conflict resolved, The program does not affect other features.
3. When updating, note the list of updated files, and if an update is generated during the submission process, you will need to recompile and complete some of your own necessary tests before committing. This will allow you to understand what files others have modified, and also avoid SVN merge errors that lead to code mistakes.
two. Keep the atomic commit
Each commit interval is as short as possible, with a few hours of development work advisable. For example, when changing the UI interface, it can be submitted once for each UI modification or design. In the development of the function module, you can complete a small details of the function of the test, submitted once, in the modification of the bug, each modified a bug and confirmed that the bug was modified, also submitted once. We advocate multiple submissions, and we can add more insurance to the code.
three. When SVN commits, be careful not to submit locally generated files automatically
The general configuration administrator submits some automatically generated files in the project or file screens related to the local configuration environment (for example,. classpath files in Eclipse, etc.). If this is not configured in the project to forcibly prohibit the submission of such a file, please do not submit such a file consciously. After submitting such a document, others may conflict with the local environment in order to affect the work of the people after the update.
Four. Do not submit code that cannot be compiled
Before committing the code, you must first confirm that you are able to compile locally. If you use a third-party class library in your code, consider that some members of the project group may not have the appropriate third-party class library installed. When the project manager prepares the project workspace, it is necessary to ensure that the development team members are able to compile in a unified environment after the code is checked out.
Five. Do not submit code that you do not understand
After the code is submitted to SVN, your code will be shared by the project's members. If you do not understand the submission of code, you do not understand, others can not understand, if in the future problems will become the project quality of the hidden danger. So before you introduce any third-party code, make sure you have a clear understanding of the code.
Six. The project team members ' work plan is coordinated in advance by SVN submission.
The project manager should allocate the work plan reasonably. Before each member is ready to start making changes to a feature, if possible, talk to a member of the working Group about his or her modification plan so that everyone can understand your thoughts and understand the changes you are about to make to the software, so as to minimize any conflicts that may arise during the development process and improve the efficiency of development. At the same time you can find yourself in the communication with the members of the shortcomings of the previous design, improve your design.
Seven. Use clear annotations for SVN-submitted information
Using SVN in a project group, if you submit an empty callout or an inaccurate callout will make the other members of the team feel helpless, the project manager can not clearly grasp the progress of the work, unable to clearly grasp the submission of the summary information. It is not possible to locate the file that caused the error correctly after the error is found. Therefore, when submitting a job, to fill in the clear annotations, can outline the information submitted to the file, so that the other members of the project team can see the label without a detailed look at the code to understand the changes you made.
Eight. Use lock function with caution
In the project, you should use the locking feature carefully, after you lock a file, others will not be able to continue to modify the submission of the file, although you can reduce the incidence of conflicts, but may affect the work of other people in the project team. Usually only when editing the files that cannot be merged (such as file, flash files, etc.), the appropriate locking operation. This article explains some of the issues that you should pay attention to in SVN submission, and please follow this section for other relevant reports.

SVN Commit Update

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.