Tutorial 3 overwrite submission. 2. Revert
To save time, this tutorial uses existing history as the local database.
Download from here
We will use the revert command to cancel the "Add pull Tutorial" submission.
First enter the Stepup-tutorial/tutorial2 directory. The status of the local side's history is shown in the following figure.
Confirm History with log command
$ git log
commit 0d4a808c26908cd5fe4b6294a00150342d1a58be
author:yourname <yourname@yourmail.com>
Date: Mon June 23:19:26 +0900
Add pull description
commit 9a54fd4dd22dbe22dd966581bc78e83f16cee1d7
author:yourname <yourname@yourmail.com>
Date: Mon June 23:19:01 +0900
Add a description of the commit
326fc9f70d022afdd31b0072dbbae003783d77ed
author:yourname <yourname@yourmail.com>
Date: Mon June 23:17:56 +0900
Add the description of the add to
commit 48eec1ddf73a7fb508ef664efd6b3d873631742f
author:yourname <yourname@yourmail.com>
Date: Mon June 23:16:14 +0900
Open the Sample.txt file and confirm the contents.
Even the monkeys know it. Git command
Add change entry into the index
the status of the commit record index
pull get the content of the remote database
Use revert to cancel the "Add pull Tutorial" submission.
$ git revert head
[master d47bb1d] revert "add pull description"
1 files changed, 1 insertions (+), 2 deletions (-)
Open the Sample.txt file to see if the pull's description disappears, indicating that the cancellation was successful.
Confirm History with log command
$ git log
commit 7bcf5e3b6fc47e875ec226ce2b13a53df73cf626
author:yourname <yourname@yourmail.com>
Date: Wed June 15:46:28 +0900
Revert "Instructions for adding pull" This
reverts commit 0d4a808c26908cd5fe4b6294a00150342d1a58be.
Commit 0d4a808c26908cd5fe4b6294a00150342d1a58be
Author:yourname <yourname@yourmail.com>
Date: Mon 23:19:26 +0900
Add a description
of Pull Commit 9a54fd4dd22dbe22dd966581bc78e83f16cee1d7
author:yourname <yourname@yourmail.com>
Date: Mon June 23:19:01 +0900
Add a description of a commit
commit 326fc9f70d022afdd31b0072dbbae003783d77ed
Author:yourname <yourname@yourmail.com>
Date: Mon 23:17:56 +0900
Add a note
Commit 48eec1ddf73a7fb508ef664efd6b3d873631742f
author:yourname <yourname@yourmail.com>
Date: Mon June 23:16:14 +0900
From:http://backlogtool.com/git-guide/cn/stepup/stepup7_2.html