On Wed, 2008-12-24 at 16:15 -0800, John Gardiner Myers wrote:
> The following patch passes the name of the conflicted file to the merge
> tool, so it can apply local knowledge based on that name.
John,
I love this, I see the need for it, I just can't spend time on it now. I
would want to check how it affects compatibility, whether there are
other similar cases that should be handled too (interactive resolution
has a similar problem, for example, and I think there's more than one
place where merge is called, I think) and so on.
If you could answer some of those questions that would help, though I
still probably can't get to it any sooner.
I have your email marked for attention.
Thanks.
- Julian
> I would like to have it also pass the names of the left-version and
> right-version, but svn_wc_merge3() has filling in that information
> marked as a TODO comment.
>
>
> [[[
> * subversion/svn/cl.h,
> subversion/svn/util.c,
> subversion/svn/conflict-callbacks.c: Pass the name of the conflicted
> file to the merge tool
> ]]]
> Index: subversion/svn/cl.h
> ===================================================================
> --- subversion/svn/cl.h (revision 34905)
> +++ subversion/svn/cl.h (working copy)
> @@ -480,6 +480,7 @@
>
> /* Search for a merge tool command in environment variables,
> and use it to perform the merge of the four given files.
> + WC_NAME is the name of the file that is in conflict.
> Use POOL for all allocations.
>
> CONFIG is a hash of svn_config_t * items keyed on a configuration
> @@ -490,6 +491,7 @@
> const char *their_path,
> const char *my_path,
> const char *merged_path,
> + const char *wc_name,
> apr_hash_t *config,
> apr_pool_t *pool);
>
> Index: subversion/svn/util.c
> ===================================================================
> --- ../svn-trunk2/subversion/svn/util.c 2008-12-24 15:51:48.000000000 -0800
> +++ subversion/svn/util.c 2008-12-24 16:07:19.000000000 -0800
> @@ -200,6 +200,7 @@
> const char *their_path,
> const char *my_path,
> const char *merged_path,
> + const char *wc_name,
> apr_hash_t *config,
> apr_pool_t *pool)
> {
> @@ -239,7 +240,7 @@
>
> {
> const char *arguments[] = { merge_tool, base_path, their_path,
> - my_path, merged_path, NULL};
> + my_path, merged_path, wc_name, NULL};
> char *cwd;
> int exitcode;
> apr_status_t status = apr_filepath_get(&cwd, APR_FILEPATH_NATIVE,
> pool);
> Index: subversion/svn/conflict-callbacks.c
> ===================================================================
> --- subversion/svn/conflict-callbacks.c (revision 34905)
> +++ subversion/svn/conflict-callbacks.c (working copy)
> @@ -219,7 +219,7 @@
>
> err = svn_cl__merge_file_externally(desc->base_file, desc->their_file,
> desc->my_file, desc->merged_file,
> - b->config, pool);
> + desc->path, b->config, pool);
> if (err && err->apr_err == SVN_ERR_CL_NO_EXTERNAL_MERGE_TOOL)
> {
> SVN_ERR(svn_cmdline_fprintf(stderr, pool, "%s\n",
> @@ -336,6 +336,7 @@
> desc->their_file,
> desc->my_file,
> desc->merged_file,
> + desc->path,
> b->config,
> pool);
> if (err && err->apr_err == SVN_ERR_CL_NO_EXTERNAL_MERGE_TOOL)
>
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=991988
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=1013973
Received on 2009-01-09 17:07:21 CET