Skip to content

Cherry-pick

What is Cherry-pick?

A cherry-pick applies the changes from one specific commit onto your current branch as a new commit, without merging the rest of the branch it came from.

The act of selecting a single, specific commit from one branch and applying it independently to another branch.

Cherry-picking takes the exact changes introduced in one commit and duplicates them onto your current branch. Instead of merging an entire branch's history, it surgically extracts just the work from the specific commit you need.

How it relates to Orbit

Orbit lands a finished run through Git, and a cherry-pick is one way to move a single run’s commit onto another branch by hand. See Git Tab & Recovery for details.

When you would use it

You reach for cherry-pick when someone else has written a helpful commit on a different branch, and you need just that code without merging the rest of their unfinished work.

Common operations

  • Pulling a specific bug fix from an experimental branch into the main branch.
  • Backporting a security patch to an older release version.

Frequently asked questions

When is cherry-picking useful?

To bring a single fix, such as a hotfix, onto a release branch without taking unrelated work along with it.

Does cherry-pick keep the same commit hash?

No. The change is recreated as a new commit with a new hash, which is why cherry-picked work can appear twice in history.

Related terms

Where this is taught

No learning path uses this term yet. Browse the Learning Atlas for guided sequences through related ideas.