"Git" Git usage summary

Source: Internet
Author: User
The difference between git and the traditional version management of SVN and TFS:
  1. Local machines also have branching, code-base concepts
  2. The common practice of SVN is to commit to the repository every time a code is written, but Git commits to the local (commit) and synchronizes the local code to the server (push) when there is a stable version locally.
  3. Because the local also has the code warehouse, so the remote warehouse failure, the programmer can also enjoy the code of the submission, rollback, etc., can wait for the final network recovery last one-time commit.
  4. The disadvantage of git is that the team must have a full-time code-merging staff to merge the code that everyone submits (everyone changes the batch before committing, and the conflict happens very often).
The command logs encountered in Git daily use:

1. Add all newly added files to staging area, and note that there is a space and a decimal point behind it.

git Add.

2. Submit to Local

" Submit a Comment "

3.push to remote, where Origin refers to the remote host name, develop refers to the remote branch name

Git push origin develop

4. Download the latest remote code to local, and merge with local code, again, origin refers to the remote host name, develop refers to the remote branch name

Git pull origin Develop

"Git" Git usage summary

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.