How do I resolve file conflicts with Git in Windows?

Source: Internet
Author: User
Tags using git

What if you want to add a change to the new branch you want to merge before merging the pull request to our main branch?
  A : just go back to Windows to make changes to the files in the new branch and save them, then open the CMD console to do the git command.

When we first started using Git and GitHub, it was recommended that you do not make any changes to the files on the GitHub site, but instead perform the desired modifications and other work on the local computer copy.
This helps us to effectively avoid file conflicts. In fact, we just make the changes on the local computer copy and this project is my one-person maintenance, then my local code will always be in sync with the code above GitHub.
However , if you are collaborating with others in a team, someone will push a change to the remote branch while I am working, and this change is the same file as the one we are making on the local computer, which can cause file conflicts.
This is a fairly common problem. So we need to practice creating and repairing conflicts.

Demonstrates the intent to create a file conflict by committing changes on the GitHub Web site and committing changes on the local computer copy.

As shown in the following:

Open a local file for conflict merging.

How do I resolve file conflicts with Git in Windows?

Related Article

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.