Code management in Git's general development process

Source: Internet
Author: User

Code management in the general development process

1. Download the code from the repository

git clone ssh://[email protected]192.168.1.3: 29418/mustang-web

2. Open a new branch for a feature (e.g. Instance-lanuch)

CD Mustang-web
Git checkout-b instance-lanuch
One sentence: Each time from master synchronization code, it is best to perform Pip Install-r Requirments.txt, to ensure that the new library is installed
You can view the currently owned branch git branch
  • Instance-launch
    Master

3. Modify the code in Instance-launch, such as Add, edit, delete, etc.
4. Submit to the local code base

git Add.
Git commit-m ' instance launch feature '

5. Submit the code to Gerrit for everyone review

Because there are many people in the collaborative development, there will be the main branch Master Update more frequently, your Instance-lanuch branch based on the master branch is possible and outdated, so before committing to Gerrit need to resolve some code conflicts
Run git rebase master first to see if there is a conflict, if any, after resolving the conflict git rebase--continue
Git review commit to Gerrit

6. When the review is complete, your code will be merged into the master branch master

Update to local Master branch

git checkout Master
Git pull

7. When developing the next feature, start with step 2

Note:
Profile: http://blog.jobbole.com/25775/

Code management in Git's general development process

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.