git cherry-pick --continue

Resume an in-progress cherry-pick after resolving conflicts.

This command lets you continue applying a previously selected commit once you’ve fixed any merge conflicts that occurred during the cherry-pick operation, finalizing the change into your current branch.

This command is used in the middle of a cherry-pick workflow: after you ran something like git cherry-pick <commit> and Git stopped because of conflicts, you fix the conflicting files, run git add on the resolved files, and then use this command to tell Git that the conflicts are resolved so it can complete the cherry-pick; the --continue flag (same as -c when supported by your Git version) specifically means “proceed with the in-progress cherry-pick using the current index and working tree state.” If you decide you don’t want to keep the partial cherry-pick, you can instead use git cherry-pick --abort to restore the branch to the state before the cherry-pick started, or git cherry-pick --quit to stop the operation but keep the index and working tree as they are, allowing you to inspect or manually commit changes.

This command is most useful when cherry-picking a commit that doesn’t apply cleanly, because it lets you manually resolve conflicts and then finish the operation in a controlled way; it will create a new commit on the current branch that has the same changes as the original commit (but usually a different commit hash), and it preserves the original commit message unless you edit it. In more complex situations, such as cherry-picking a range like git cherry-pick A..B, you may need to use this command multiple times—once for each conflicting commit—after resolving conflicts at each step.

Other related commands include git cherry-pick <commit> for starting a cherry-pick, git cherry-pick --abort to cancel a problematic cherry-pick and roll back to the pre-cherry-pick state, and git cherry-pick --quit to exit without rolling back changes to your working directory; for applying changes from another branch you might also compare with git merge <branch> or git rebase <branch>, though these operate on whole branch histories rather than specific commits and have their own --continue, --abort, and --quit flows for conflict resolution.

Examples:

  • git cherry-pick a1b2c3d4
  • git cherry-pick feature-branch
  • git cherry-pick 1234abcd..7890efgh
Manual page
git cherry-pick
Related commands

Welcome to GitExamples!

Sign in to gitexamples