[PATCH 1/2] rebase -i: run "commit --amend" with verbose if rebase was called with -v
- From
Andrew Wong <andrew.kw.w@gmail.com>
- Date
- Jul 25, 2011, 03:38 UTC
- Message-ID
- <1311565113-5022-2-git-send-email-andrew.kw.w@gmail.com>
- In-Reply-To
- <1311565113-5022-1-git-send-email-andrew.kw.w@gmail.com>
This provides a convenient way to inspect the diff while rewording commits, which is really useful when rewording commit messages that are unclear.
Signed-off-by: Andrew Wong <andrew.kw.w@gmail.com> --- git-rebase--interactive.sh | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh index c6ba7c1..df9f7e9 100644 --- a/git-rebase--interactive.sh +++ b/git-rebase--interactive.sh @@ -392,10 +392,12 @@ do_next () { reword|r) comment_for_reflog reword + test t = "$verbose" && commit_verbose_flag=--verbose + mark_action_done pick_one $sha1 || die_with_patch $sha1 "Could not apply $sha1... $rest" - git commit --amend --no-post-rewrite + git commit $commit_verbose_flag --amend --no-post-rewrite record_in_rewritten $sha1 ;; edit|e)
-- 1.7.2.2