roadrunnertwice: Dee perpetrates some Mess. (Arts and crafts (Little Dee))
Nick Eff ([personal profile] roadrunnertwice) wrote 2023-09-25 04:15 pm (UTC)

Cherry-pick means “treat this arbitrary commit as though it were a set of edits, and try to perform those same edits on the current code (which presumably has never had those edits applied before).”

So, if the commit added a new function and changed another function to call it, cherry-picking would make a new commit on your current branch to add that new function and call it.

It’s a speculative history re-write: “what if I had made those edits here and now, instead of on another branch somewhere?”

If those edits wouldn’t have made sense on the current branch (like, the file you added the function to is gone), then you get a conflict and probably want to abort, since you’re probably outside the set of situations where cherry-picking would save you any time or effort.


Post a comment in response:

This account has disabled anonymous posting.
(will be screened if not validated)
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

If you are unable to use this captcha for any reason, please contact us by email at support@dreamwidth.org