Signed-off-by: Nguyễn Thái Ngọc Duy
---
- fix bisecting on detached HEAD
- show onto sha-1 for rebase
t/t7512-status-help.sh | 36 ++--
wt-status.c| 91 ++
wt-status.h| 2 ++
3 files changed, 105 insertions(+), 24 deletions(-)
diff --git a/t/t7512-status-help.sh b/t/t7512-status-help.sh
index b3f6eb9..67ece6b 100755
--- a/t/t7512-status-help.sh
+++ b/t/t7512-status-help.sh
@@ -76,7 +76,7 @@ test_expect_success 'status when rebase in progress before
resolving conflicts'
test_must_fail git rebase HEAD^ --onto HEAD^^ &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently rebasing.
+ # You are currently rebasing branch '\''rebase_conflicts'\'' on
'\''000106f'\''.
# (fix conflicts and then run "git rebase --continue")
# (use "git rebase --skip" to skip this patch)
# (use "git rebase --abort" to check out the original branch)
@@ -102,7 +102,7 @@ test_expect_success 'status when rebase in progress before
rebase --continue' '
git add main.txt &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently rebasing.
+ # You are currently rebasing branch '\''rebase_conflicts'\'' on
'\''000106f'\''.
# (all conflicts fixed: run "git rebase --continue")
#
# Changes to be committed:
@@ -133,7 +133,7 @@ test_expect_success 'status during rebase -i when conflicts
unresolved' '
test_must_fail git rebase -i rebase_i_conflicts &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently rebasing.
+ # You are currently rebasing branch '\''rebase_i_conflicts_second'\''
on '\''e0164e4'\''.
# (fix conflicts and then run "git rebase --continue")
# (use "git rebase --skip" to skip this patch)
# (use "git rebase --abort" to check out the original branch)
@@ -158,7 +158,7 @@ test_expect_success 'status during rebase -i after
resolving conflicts' '
git add main.txt &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently rebasing.
+ # You are currently rebasing branch '\''rebase_i_conflicts_second'\''
on '\''e0164e4'\''.
# (all conflicts fixed: run "git rebase --continue")
#
# Changes to be committed:
@@ -185,7 +185,7 @@ test_expect_success 'status when rebasing -i in edit mode' '
git rebase -i HEAD~2 &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently editing a commit during a rebase.
+ # You are currently editing a commit while rebasing branch
'\''rebase_i_edit'\'' on '\''f90e540'\''.
# (use "git commit --amend" to amend the current commit)
# (use "git rebase --continue" once you are satisfied with your
changes)
#
@@ -210,7 +210,7 @@ test_expect_success 'status when splitting a commit' '
git reset HEAD^ &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently splitting a commit during a rebase.
+ # You are currently splitting a commit while rebasing branch
'\''split_commit'\'' on '\''19b175e'\''.
# (Once your working directory is clean, run "git rebase --continue")
#
# Changes not staged for commit:
@@ -240,7 +240,7 @@ test_expect_success 'status after editing the last commit
with --amend during a
git commit --amend -m "foo" &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently editing a commit during a rebase.
+ # You are currently editing a commit while rebasing branch
'\''amend_last'\'' on '\''dd030b9'\''.
# (use "git commit --amend" to amend the current commit)
# (use "git rebase --continue" once you are satisfied with your
changes)
#
@@ -269,7 +269,7 @@ test_expect_success 'status: (continue first edit) second
edit' '
git rebase --continue &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently editing a commit during a rebase.
+ # You are currently editing a commit while rebasing branch
'\''several_edits'\'' on '\''eb16a7e'\''.
# (use "git commit --amend" to amend the current commit)
# (use "git rebase --continue" once you are satisfied with your
changes)
#
@@ -290,7 +290,7 @@ test_expect_success 'status: (continue first edit) second
edit and split' '
git reset HEAD^ &&
cat >expected <<-\EOF &&
# Not currently on any branch.
- # You are currently splitting a commit during a rebase.
+ # You are currently splitting a commit while rebasing branch
'\''several_edits'\'' on '\''eb16a7e'\''.
# (Once your working directory is clean, run "git rebase --continue")
#
# Change