threads / patch / 13054

patchForce the medium pretty format on calls to git log

Subject: [PATCH] Force the medium pretty format on calls to git log

## tl;dr

2 messages between Apr 10, 2008 and Apr 11, 2008. Diffs are folded; open one to read it.

replies: 1people: 2as markdown or json

Pedro Melo· Apr 10, 2008, 16:05 UTC · lore
If a user as set a format.pretty in his config, git-svn rebase will fail with:
Unable to determine upstream SVN information from working tree history
We need to force the medium format to obtain the needed information from the log.
Signed-off-by: Pedro Melo <melo@simplicidade.org>
---
 git-svn.perl |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
Show changes to git-svn.perl +1 −1
diff --git a/git-svn.perl b/git-svn.perl
index 81afb5c..b864b54 100755
--- a/git-svn.perl
+++ b/git-svn.perl
@@ -1120,7 +1120,7 @@ sub cmt_metadata {
 
 sub working_head_info {
 	my ($head, $refs) = @_;
-	my @args = ('log', '--no-color', '--first-parent');
+	my @args = ('log', '--no-color', '--first-parent', '--pretty=medium');
 	my ($fh, $ctx) = command_output_pipe(@args, $head);
 	my $hash;
 	my %max;
-- 
1.5.5.23.g2a5f
Junio C Hamano· Apr 11, 2008, 05:41 UTC · re: Pedro Melo · lore

Re: [PATCH] Force the medium pretty format on calls to git log

Pedro Melo <melo@simplicidade.org> writes:
Show 9 quoted lines
> If a user as set a format.pretty in his config, git-svn rebase will fail
> with:
>
> Unable to determine upstream SVN information from working tree history
>
> We need to force the medium format to obtain the needed information from
> the log.
>
> Signed-off-by: Pedro Melo <melo@simplicidade.org>

Thanks. This should have been part of 9225d7b (specify explicit "--pretty=medium" with `git log/show/whatchanged`, 2008-03-02) but apparently we did not do a thorough job.

← back to recent threads