The solution for git rebase, pull, and push cannot be merge after conflict appears

Source: Internet
Author: User
Tags using git git mergetool

We often encounter conflicts when using git rebase, pull, and push. At this time, we will go to merge:

$ git rebase master

Conflict:

$ git mergetool -t opendiff

Then, use opendiff to manually merge the conflicting location.

However, today I met a situation where merge is not available. The problem is as follows:

$ git mergetool -t opendiff
$ no files need merging

I am prompted that merging is not required for files. I found the solution on Google. There are generally two solutions:

First:

$git config --global core.trustctime false

The preceding statement is as follows:

If false, the ctime differences between the index and the working copy are ignored; useful when the inode change time is regularly modified by something outside git (File System crawlers and some backup systems ). and core. trustctime is true by default.

Therefore, setting it directly to false is not a problem, as long as the content of the Code is consistent.

Second:

$git rebase --skip

You can directly Skip, because no file requires merging, indicating that the conflict is not in the file content.

Solve the problem.

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.