threads / patch / 22452

patchrebase: don't invoke the pager for each commit summary

Subject: [PATCH] rebase: don't invoke the pager for each commit summary

## tl;dr

5 messages between Jan 30, 2010 and Feb 1, 2010. Diffs are folded; open one to read it.

replies: 4people: 3as markdown or json

Markus Heidelberg· Jan 30, 2010, 16:23 UTC · lore

This regression was introduced by commit 0aa958d (rebase: replace antiquated sed invocation, 2010-01-24), which changed the invocation of "git rev-list | sed" to "git log".

It can be reproduced by something like this: $ git rebase -s recursive origin/master

Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
---
 git-rebase.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Show changes to git-rebase.sh +1 −1
diff --git a/git-rebase.sh b/git-rebase.sh
index b5d9178..fb4fef7 100755
--- a/git-rebase.sh
+++ b/git-rebase.sh
@@ -86,7 +86,7 @@ continue_merge () {
 		fi
 	fi
 	test -z "$GIT_QUIET" &&
-	git log --format=%s -1 "$cmt"
+	GIT_PAGER='' git log --format=%s -1 "$cmt"
 
 	prev_head=`git rev-parse HEAD^0`
 	# save the resulting commit so we can read-tree on it later
-- 
1.7.0.rc0.71.g95b6e
Johannes Schindelin· Jan 30, 2010, 16:47 UTC · re: Markus Heidelberg · lore

Re: [PATCH] rebase: don't invoke the pager for each commit summary

Hi,
On Sat, 30 Jan 2010, Markus Heidelberg wrote:
Show 10 quoted lines
> diff --git a/git-rebase.sh b/git-rebase.sh
> index b5d9178..fb4fef7 100755
> --- a/git-rebase.sh
> +++ b/git-rebase.sh
> @@ -86,7 +86,7 @@ continue_merge () {
>  		fi
>  	fi
>  	test -z "$GIT_QUIET" &&
> -	git log --format=%s -1 "$cmt"
> +	GIT_PAGER='' git log --format=%s -1 "$cmt"
Would it not be better 'git --no-pager log [...]'?

Ciao, Dscho

Markus Heidelberg· Jan 30, 2010, 16:46 UTC · re: Johannes Schindelin · lore

Re: [PATCH] rebase: don't invoke the pager for each commit summary

Johannes Schindelin, 2010-01-30:
Show 16 quoted lines
> Hi,
> 
> On Sat, 30 Jan 2010, Markus Heidelberg wrote:
> 
> > diff --git a/git-rebase.sh b/git-rebase.sh
> > index b5d9178..fb4fef7 100755
> > --- a/git-rebase.sh
> > +++ b/git-rebase.sh
> > @@ -86,7 +86,7 @@ continue_merge () {
> >  		fi
> >  	fi
> >  	test -z "$GIT_QUIET" &&
> > -	git log --format=%s -1 "$cmt"
> > +	GIT_PAGER='' git log --format=%s -1 "$cmt"
> 
> Would it not be better 'git --no-pager log [...]'?
That was my initial fix, but then I found this in line 519:
        GIT_PAGER='' git diff --stat --summary "$mb" "$onto"
and decided to keep consistency.
Don't know.
Markus
Markus Heidelberg· Jan 30, 2010, 16:52 UTC · re: Markus Heidelberg · lore

Re: [PATCH] rebase: don't invoke the pager for each commit summary

Markus Heidelberg, 2010-01-30:
> Johannes Schindelin, 2010-01-30:
> > Date:	Sat, 30 Jan 2010 17:47:11 +0100 (CET)
> Date:	Sat, 30 Jan 2010 17:46:13 +0100
You should adjust your clock :)
Markus
Stephen Boyd· Feb 1, 2010, 05:39 UTC · re: Markus Heidelberg · lore

Re: [PATCH] rebase: don't invoke the pager for each commit summary

On Sat, Jan 30, 2010 at 8:23 AM, Markus Heidelberg <markus.heidelberg@web.de> wrote:

Show 9 quoted lines
> This regression was introduced by commit 0aa958d (rebase: replace
> antiquated sed invocation, 2010-01-24), which changed the invocation of
> "git rev-list | sed" to "git log".
>
> It can be reproduced by something like this:
> $ git rebase -s recursive origin/master
>
> Signed-off-by: Markus Heidelberg <markus.heidelberg@web.de>
>
Thanks. Maybe you can use git show too instead of git log -1?

← back to recent threads