git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] git-svn: merge: fix rooturl/branchurl match check

From
EWEric Wong <normalperson@yhbt.net>
Date
Oct 20, 2014, 06:24 UTC
Message-ID
<20141020062413.GB27885@dcvr.yhbt.net>
In-Reply-To
<BLU437-SMTP152A16338E427B250EB601FBAA0@phx.gbl>
Tommaso Colombo <tommaso.colombo@outlook.com> wrote:
Show 9 quoted lines
> When populating svn:mergeinfo, git-svn merge checks if the merge parent
> of the merged branch is under the same root as the git-svn repository.
> This was implemented comparing $gs->repos_root with the return value of
> of cmt_metadata for the merge parent. However, the first may contain a
> username, whereas the second does not. In this case the comparison
> fails.
> 
> Remove the username from $gs->repos_root before performing the
> comparison.

Thanks. Commit makes sense, but one of the test cases fails for me, can you check it out? $ make && make t9161-git-svn-mergeinfo-push.sh -C t GIT_TEST_OPTS='-i -v' <snip successes> ok 11 - reintegration merge

expecting success: 
	mergeinfo=$(svn_cmd propget svn:mergeinfo "$svnrepo"/branches/svnb4)
	test "$mergeinfo" = "/branches/svnb1:2-4,7-9,13-18
/branches/svnb2:3,8,16-17
/branches/svnb3:4,9
/branches/svnb5:6,11"
	
not ok 12 - check reintegration mergeinfo
#	
#		mergeinfo=$(svn_cmd propget svn:mergeinfo "$svnrepo"/branches/svnb4)
#		test "$mergeinfo" = "/branches/svnb1:2-4,7-9,13-18
#	/branches/svnb2:3,8,16-17
#	/branches/svnb3:4,9
#	/branches/svnb5:6,11"
#		
make: *** [t9161-git-svn-mergeinfo-push.sh] Error 1
make: Leaving directory `/home/ew/git-core/t'

You'll also need to sign-off (see Documentation/SubmittingPatches) It is required (project policy, not mine)

Show 6 quoted lines
> @@ -729,7 +730,7 @@ sub populate_merge_info {
>  			}
>  			my $branchpath = $1;
>  
> -			my $ra = Git::SVN::Ra->new($branchurl);
> +			my $ra = Git::SVN::Ra->new(add_path_to_url($gs->repos_root, $branchpath));

Also, please keep long lines wrapped to <= 80 columns. Thanks again.

Previous: Tommaso Colombo
Message 2 of 2 in “git-svn: merge: fix rooturl/branchurl match check”
  1. git-svn: merge: fix rooturl/branchurl match checkTommaso Colombo, Oct 15, 2014
  2. Eric WongOct 20, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.