For this tutorial step, we have prepared a repository with some ready made commits to speed things up.

You can download the repository here.

Go to the downloaded "stepup-tutorial/tutorial4" directory and examine the history of this repository. It should look like the following.

In this step, we are going to create a new commit in the master branch that is a copy of the commit with the message "append description of the commit command" residing on a different branch within the same repository.

Current history

Switch over to the master branch. Use the cherry-pick command and specify the commit hash for "append description of the commit command".

The commit hash "99daed2" may differ on your local repository. You can obtain the commit hash by running "git log" in that branch. Find out the commit hash on your local repository and use that instead.

$ git checkout master Switched to branch 'master' $ git cherry-pick 99daed2 error: could not apply 99daed2... commit hint: after resolving the conflicts, mark the corrected paths hint: with 'git add <paths>' or 'git rm <paths>' hint: and commit the result with 'git commit'

As you can see here, a conflict has occured. Manually resolve it and proceed with committing the change.

$ git add sample.txt $ git commit