You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Daniel Rall <dl...@collab.net> on 2007/02/15 00:02:07 UTC

[merge-tracking] Setting src_rel for WC -> URL copy/move

svn_client__copy_pair_t->src_rel is currently only set for URL -> WC
copy/move operations.  I'd like to also set it for WC -> URL ops.
Does this sound reasonable?

I'm currently playing around with this patch:

Index: copy.c
===================================================================
--- copy.c	(revision 23396)
+++ copy.c	(working copy)
@@ -988,6 +988,10 @@
       svn_client__copy_pair_t *pair = APR_ARRAY_IDX(copy_pairs, i,
                                                     svn_client__copy_pair_t *);
 
+      SVN_ERR(svn_client__path_relative_to_root(&pair->src_rel, pair->src,
+                                                NULL, ra_session, adm_access,
+                                                pool));
+
       pair->dst_rel = svn_path_is_child(top_dst_url, pair->dst, pool);
       SVN_ERR(svn_ra_check_path(ra_session, 
                                 svn_path_uri_decode(pair->dst_rel, pool),

Re: [merge-tracking] Setting src_rel for WC -> URL copy/move

Posted by "Hyrum K. Wright" <hy...@mail.utexas.edu>.
Daniel Rall wrote:
> svn_client__copy_pair_t->src_rel is currently only set for URL -> WC
> copy/move operations.  I'd like to also set it for WC -> URL ops.
> Does this sound reasonable?

Yes, that should work fine.  We should probably adjust the doc string to
reflect the fact that src_rel can be used for paths relative to both the
wc root and the repository root, depending on context.

> I'm currently playing around with this patch:
> 
> Index: copy.c
> ===================================================================
> --- copy.c	(revision 23396)
> +++ copy.c	(working copy)
> @@ -988,6 +988,10 @@
>        svn_client__copy_pair_t *pair = APR_ARRAY_IDX(copy_pairs, i,
>                                                      svn_client__copy_pair_t *);
>  
> +      SVN_ERR(svn_client__path_relative_to_root(&pair->src_rel, pair->src,
> +                                                NULL, ra_session, adm_access,
> +                                                pool));
> +
>        pair->dst_rel = svn_path_is_child(top_dst_url, pair->dst, pool);
>        SVN_ERR(svn_ra_check_path(ra_session, 
>                                  svn_path_uri_decode(pair->dst_rel, pool),

-Hyrum