Index: subversion/include/svn_wc.h =================================================================== --- subversion/include/svn_wc.h (revision 31150) +++ subversion/include/svn_wc.h (working copy) @@ -909,6 +909,11 @@ left and right sides of the merge are from the same URL. In all other cases, it is @c NULL. */ svn_merge_range_t *merge_range; + /** If non-NULL, specifies an absolute path prefix that can be subtracted + * from the start of the absolute path in @c path. Its purpose is to + * allow notification to remove a common prefix from all the paths + * displayed for an operation. @since New in 1.6 */ + const char *path_prefix; /* NOTE: Add new fields at the end to preserve binary compatibility. Also, if you add fields here, you have to update svn_wc_create_notify and svn_wc_dup_notify. */ Index: subversion/libsvn_wc/util.c =================================================================== --- subversion/libsvn_wc/util.c (revision 31150) +++ subversion/libsvn_wc/util.c (working copy) @@ -128,6 +128,7 @@ ret->revision = SVN_INVALID_REVNUM; ret->changelist_name = NULL; ret->merge_range = NULL; + ret->path_prefix = NULL; return ret; } @@ -164,6 +165,8 @@ ret->changelist_name = apr_pstrdup(pool, ret->changelist_name); if (ret->merge_range) ret->merge_range = svn_merge_range_dup(ret->merge_range, pool); + if (ret->path_prefix) + ret->path_prefix = apr_pstrdup(pool, ret->path_prefix); return ret; } Index: subversion/libsvn_client/client.h =================================================================== --- subversion/libsvn_client/client.h (revision 31150) +++ subversion/libsvn_client/client.h (working copy) @@ -915,9 +915,8 @@ CTX->NOTIFY_FUNC/CTX->BATON will be called as the commit progresses, as a way of describing actions to the application layer (if non NULL). - NOTIFY_PATH_PREFIX is used to send shorter, relative paths to the - notify_func (it's a prefix that will be subtracted from the front - of the paths.) + NOTIFY_PATH_PREFIX will be passed to CTX->notify_func2() as common absolute + path prefix of the committed absolute paths. If the caller wants to keep track of any outstanding temporary files left after the transmission of text and property mods, Index: subversion/libsvn_client/commit_util.c =================================================================== --- subversion/libsvn_client/commit_util.c (revision 31150) +++ subversion/libsvn_client/commit_util.c (working copy) @@ -1080,7 +1080,6 @@ svn_wc_adm_access_t *adm_access = cb_baton->adm_access; const svn_delta_editor_t *editor = cb_baton->editor; apr_hash_t *file_mods = cb_baton->file_mods; - const char *notify_path_prefix = cb_baton->notify_path_prefix; svn_client_ctx_t *ctx = cb_baton->ctx; /* Do some initializations. */ @@ -1121,20 +1120,9 @@ describe what we're about to do to this item. */ if (ctx->notify_func2) { - /* Convert an absolute path into a relative one (if possible.) */ - const char *npath = NULL; + const char *npath = item->path; svn_wc_notify_t *notify; - if (notify_path_prefix) - { - if (strcmp(notify_path_prefix, item->path)) - npath = svn_path_is_child(notify_path_prefix, item->path, pool); - else - npath = "."; - } - if (! npath) - npath = item->path; /* Otherwise just use full path */ - if ((item->state_flags & SVN_CLIENT_COMMIT_ITEM_DELETE) && (item->state_flags & SVN_CLIENT_COMMIT_ITEM_ADD)) { @@ -1183,6 +1171,7 @@ if (notify) { notify->kind = item->kind; + notify->path_prefix = cb_baton->notify_path_prefix; (*ctx->notify_func2)(ctx->notify_baton2, notify, pool); } } @@ -1434,22 +1423,11 @@ if (ctx->notify_func2) { svn_wc_notify_t *notify; - const char *npath = NULL; - - if (notify_path_prefix) - { - if (strcmp(notify_path_prefix, item->path) != 0) - npath = svn_path_is_child(notify_path_prefix, item->path, - subpool); - else - npath = "."; - } - if (! npath) - npath = item->path; - notify = svn_wc_create_notify(npath, + notify = svn_wc_create_notify(item->path, svn_wc_notify_commit_postfix_txdelta, subpool); notify->kind = svn_node_file; + notify->path_prefix = notify_path_prefix; (*ctx->notify_func2)(ctx->notify_baton2, notify, subpool); }