summaryrefslogtreecommitdiff
path: root/git-rebase--interactive.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2013-05-01 15:23:56 -0700
committerJunio C Hamano <gitster@pobox.com>2013-05-01 15:23:57 -0700
commitb9347eb224d7b38f29893e75b6ca16a61647a4f2 (patch)
tree049d66f4142adde81d99671df8bf0426d369132b /git-rebase--interactive.sh
parent7e6a0cc47da79dd22c0338aee8750fda92ced5d9 (diff)
parentb71dc3e1a04666fae4a4e282973d9b5a122a997c (diff)
downloadgit-b9347eb224d7b38f29893e75b6ca16a61647a4f2.tar.gz
Merge branch 'zk/prompt-rebase-step'
* zk/prompt-rebase-step: bash-prompt.sh: show where rebase is at when stopped
Diffstat (limited to 'git-rebase--interactive.sh')
-rw-r--r--git-rebase--interactive.sh5
1 files changed, 5 insertions, 0 deletions
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
index 048a140a6f..5822b2c592 100644
--- a/git-rebase--interactive.sh
+++ b/git-rebase--interactive.sh
@@ -57,6 +57,9 @@ rewritten="$state_dir"/rewritten
dropped="$state_dir"/dropped
+end="$state_dir"/end
+msgnum="$state_dir"/msgnum
+
# A script to set the GIT_AUTHOR_NAME, GIT_AUTHOR_EMAIL, and
# GIT_AUTHOR_DATE that will be used for the commit that is currently
# being rebased.
@@ -109,7 +112,9 @@ mark_action_done () {
sed -e 1d < "$todo" >> "$todo".new
mv -f "$todo".new "$todo"
new_count=$(git stripspace --strip-comments <"$done" | wc -l)
+ echo $new_count >"$msgnum"
total=$(($new_count + $(git stripspace --strip-comments <"$todo" | wc -l)))
+ echo $total >"$end"
if test "$last_count" != "$new_count"
then
last_count=$new_count