threads / patch / 33099

patchgit svn: ignore partial svn:mergeinfo

Subject: [PATCH] git svn: ignore partial svn:mergeinfo

## tl;dr

4 messages between Mar 7, 2013 and Mar 8, 2013. Diffs are folded; open one to read it.

replies: 3people: 3as markdown or json

Jan Pešta· Mar 7, 2013, 11:28 UTC · lore

Currently this is cosmetic change - the merges are ignored, becuase the methods (lookup_svn_merge, find_rev_before, find_rev_after) are failing on comparing text with number.

See http://www.open.collab.net/community/subversion/articles/merge-info.html Extract: The range r30430:30435 that was added to 1.5.x in this merge has a '*' suffix for 1.5.x\www. This '*' is the marker for a non-inheritable mergeinfo range. The '*' means that only the path on which the mergeinfo is explicitly set has had this range merged into it.

Signed-off-by: Jan Pesta <jan.pesta@certicon.cz>
---
 perl/Git/SVN.pm | 5 +++++
 1 file changed, 5 insertions(+)
Show changes to perl/Git/SVN.pm +5 −0
diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm
index 0ebc68a..74d49bb 100644
--- a/perl/Git/SVN.pm
+++ b/perl/Git/SVN.pm
@@ -1493,6 +1493,11 @@ sub lookup_svn_merge {
 	my @merged_commit_ranges;
 	# find the tip
 	for my $range ( @ranges ) {
+		if ($range =~ /[*]$/) {
+			warn "W:Ignoring partial merge in svn:mergeinfo "
+				."dirprop: $source:$range\n";
+			next;
+		}
 		my ($bottom, $top) = split "-", $range;
 		$top ||= $bottom;
 		my $bottom_commit = $gs->find_rev_after( $bottom, 1, $top );
-- 
1.8.1.msysgit.1
Eric Wong· Mar 8, 2013, 09:53 UTC · re: Jan Pešta · lore

Re: [PATCH] git svn: ignore partial svn:mergeinfo

Jan Pešta <jan.pesta@certicon.cz> wrote:
Show 10 quoted lines
> Currently this is cosmetic change - the merges are ignored, becuase the methods 
> (lookup_svn_merge, find_rev_before, find_rev_after) are failing on comparing text with number.
> 
> See http://www.open.collab.net/community/subversion/articles/merge-info.html
> Extract:
> The range r30430:30435 that was added to 1.5.x in this merge has a '*' suffix for 1.5.x\www.
> This '*' is the marker for a non-inheritable mergeinfo range.
> The '*' means that only the path on which the mergeinfo is explicitly set has had this range merged into it.
> 
> Signed-off-by: Jan Pesta <jan.pesta@certicon.cz>
Show 14 quoted lines
> ---
>  perl/Git/SVN.pm | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm
> index 0ebc68a..74d49bb 100644
> --- a/perl/Git/SVN.pm
> +++ b/perl/Git/SVN.pm
> @@ -1493,6 +1493,11 @@ sub lookup_svn_merge {
>  	my @merged_commit_ranges;
>  	# find the tip
>  	for my $range ( @ranges ) {
> +		if ($range =~ /[*]$/) {
> +			warn "W:Ignoring partial merge in svn:mergeinfo "
Thanks,

I've pushed this with a minor formatting change (added space after "W:") will push another change for formatting existing warnings more consistently.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
Eric Wong· Mar 8, 2013, 10:01 UTC · re: Eric Wong · lore

[PATCH] git svn: consistent spacing after "W:" in warnings

Eric Wong <normalperson@yhbt.net> wrote:
> will push another change for formatting existing warnings more
> consistently.
  Just pushed.  My master is sitting at git://git.bogomips.org/git-svn.git
  commit eae6cf5aa8ae2d8a90a99bbe4aeb01c29e01fd02
  Eric Wong (1):
        git svn: consistent spacing after "W:" in warnings
  Jan Pešta (1):
        git svn: ignore partial svn:mergeinfo
  I don't have further updates planned, maybe others do.
----------------------------8<------------------------------
From eae6cf5aa8ae2d8a90a99bbe4aeb01c29e01fd02 Mon Sep 17 00:00:00 2001
From: Eric Wong <normalperson@yhbt.net>
Date: Fri, 8 Mar 2013 09:46:41 +0000
Subject: [PATCH] git svn: consistent spacing after "W:" in warnings

All other instances of "W:"-prefixed warning messages have a space after the "W:" to help with readability.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
---
 perl/Git/SVN.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Show changes to perl/Git/SVN.pm +1 −1
diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm
index 46aeb85..5273ee8 100644
--- a/perl/Git/SVN.pm
+++ b/perl/Git/SVN.pm
@@ -1504,7 +1504,7 @@ sub lookup_svn_merge {
 		my $top_commit = $gs->find_rev_before( $top, 1, $bottom );
 
 		unless ($top_commit and $bottom_commit) {
-			warn "W:unknown path/rev in svn:mergeinfo "
+			warn "W: unknown path/rev in svn:mergeinfo "
 				."dirprop: $source:$range\n";
 			next;
 		}
-- 
Eric Wong
Junio C Hamano· Mar 8, 2013, 16:06 UTC · re: Eric Wong · lore

Re: [PATCH] git svn: consistent spacing after "W:" in warnings

Eric Wong <normalperson@yhbt.net> writes:
Show 6 quoted lines
> Eric Wong <normalperson@yhbt.net> wrote:
>> will push another change for formatting existing warnings more
>> consistently.
>
>   Just pushed.  My master is sitting at git://git.bogomips.org/git-svn.git
>   commit eae6cf5aa8ae2d8a90a99bbe4aeb01c29e01fd02
Thanks.
Show 35 quoted lines
>
>   Eric Wong (1):
>         git svn: consistent spacing after "W:" in warnings
>
>   Jan Pešta (1):
>         git svn: ignore partial svn:mergeinfo
>
>   I don't have further updates planned, maybe others do.
> ----------------------------8<------------------------------
> From eae6cf5aa8ae2d8a90a99bbe4aeb01c29e01fd02 Mon Sep 17 00:00:00 2001
> From: Eric Wong <normalperson@yhbt.net>
> Date: Fri, 8 Mar 2013 09:46:41 +0000
> Subject: [PATCH] git svn: consistent spacing after "W:" in warnings
>
> All other instances of "W:"-prefixed warning messages have a space after
> the "W:" to help with readability.
>
> Signed-off-by: Eric Wong <normalperson@yhbt.net>
> ---
>  perl/Git/SVN.pm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/perl/Git/SVN.pm b/perl/Git/SVN.pm
> index 46aeb85..5273ee8 100644
> --- a/perl/Git/SVN.pm
> +++ b/perl/Git/SVN.pm
> @@ -1504,7 +1504,7 @@ sub lookup_svn_merge {
>  		my $top_commit = $gs->find_rev_before( $top, 1, $bottom );
>  
>  		unless ($top_commit and $bottom_commit) {
> -			warn "W:unknown path/rev in svn:mergeinfo "
> +			warn "W: unknown path/rev in svn:mergeinfo "
>  				."dirprop: $source:$range\n";
>  			next;
>  		}

← back to recent threads