Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4027846
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T11:08:50+00:00 2026-05-20T11:08:50+00:00

This is a imaginary problem, but I’m having real problems with patches. Let’s say

  • 0

This is a imaginary problem, but I’m having real problems with patches. Let’s say I have a project with the following git history:

A - B - C

Now if I receive two patches, C1 and C2, that are meant to be applied on C, how should I handle them? If I apply patch C1 first, then I will not be able to apply patch C2 because the repository has become:

A - B - C - C1

Is it possible to apply them both, or do I have to reply to the person sending C2 telling him/her to update the patch?

Now suppose I go offline and work and commit so that the repository becomes:

A - B - C - D - E

Then I check my email and receive a patch for C. Again, is it possible to simply apply that patch, or do I have to ask for an update to the patch?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T11:08:51+00:00Added an answer on May 20, 2026 at 11:08 am

    The classic way is to:

    • apply the received first patch,
    • refuse any patch which isn’t fast-forward and ask the sender to rebase his/her repo first, then re-check the patch, and resend it.

    The general idea is that it isn’t up to you to solve merge conflicts: only the creator of the patch has the necessary knowledge to solve any conflict with the current source code.

    As Linus Torvalds (creator of Git) said in his 2007 Google talk:

    So what happens is, remember, distribution means nobody is special.
    So instead of me merging, I just push out my first tree, that did not have any merge issues, and I tell the second person:

    “hey, I tried to pull from you, but I had merge conflicts and they weren’t completely trivial, so I decided you get to do the honors instead.”

    And they do. And they know what they are doing because it’s their changes. So they can do the merges and they probably think I am a moron because the merge was so easy and it is obvious I should have taken their code, but they do the merge and they update their tree, and say “hey, can you pull from me now”, and I pull from them and they did all the work for me.

    That’s what is all about: they did all the work for me. So,… and I take the credit. Now I just need to figure out the step 3: profit.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Let say I have the following desire, to simplify the IConvertible's to allow me
Let's say I have a user class setup with validation like this: [MetadataType(typeof(ssUserMetaData))] public
This is a bit of a long shot, but if anyone can figure it
This is kinda oddball, but I was poking around with the GNU assembler today
This might seem like a stupid question I admit. But I'm in a small
This is a difficult and open-ended question I know, but I thought I'd throw
This is a sort of trivial question but something I've been wondering about. In
This has been driving me crazy for 2 days. I have been trying to
I have found this example on StackOverflow: var people = new List<Person> { new
A friend and I were discussing imaginary and real languages and a question that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.