Alien-SVN
view release on metacpan or search on metacpan
src/subversion/subversion/include/svn_client.h view on Meta::CPAN
* value. Use @a scratch_pool for temporary allocations.
*
* @since New in 1.7.
*/
svn_error_t *
svn_client_min_max_revisions(svn_revnum_t *min_revision,
svn_revnum_t *max_revision,
const char *local_abspath,
svn_boolean_t committed,
svn_client_ctx_t *ctx,
apr_pool_t *scratch_pool);
/** @} */
/**
* @defgroup Patch Apply a patch to the working copy
*
* @{
*/
/**
* The callback invoked by svn_client_patch() before attempting to patch
* the target file at @a canon_path_from_patchfile (the path as parsed from
* the patch file, but in canonicalized form). The callback can set
* @a *filtered to @c TRUE to prevent the file from being patched, or else
* must set it to @c FALSE.
*
* The callback is also provided with @a patch_abspath, the path of a
* temporary file containing the patched result, and with @a reject_abspath,
* the path to a temporary file containing the diff text of any hunks
* which were rejected during patching.
*
* Because the callback is invoked before the patching attempt is made,
* there is no guarantee that the target file will actually be patched
* successfully. Client implementations must pay attention to notification
* feedback provided by svn_client_patch() to find out which paths were
* patched successfully.
*
* Note also that the files at @a patch_abspath and @a reject_abspath are
* guaranteed to remain on disk after patching only if the
* @a remove_tempfiles parameter for svn_client_patch() is @c FALSE.
*
* The const char * parameters may be allocated in @a scratch_pool which
* will be cleared after each invocation.
*
* @since New in 1.7.
*/
typedef svn_error_t *(*svn_client_patch_func_t)(
void *baton,
svn_boolean_t *filtered,
const char *canon_path_from_patchfile,
const char *patch_abspath,
const char *reject_abspath,
apr_pool_t *scratch_pool);
/**
* Apply a unidiff patch that's located at absolute path
* @a patch_abspath to the working copy directory at @a wc_dir_abspath.
*
* This function makes a best-effort attempt at applying the patch.
* It might skip patch targets which cannot be patched (e.g. targets
* that are outside of the working copy). It will also reject hunks
* which cannot be applied to a target in case the hunk's context
* does not match anywhere in the patch target.
*
* If @a dry_run is TRUE, the patching process is carried out, and full
* notification feedback is provided, but the working copy is not modified.
*
* @a strip_count specifies how many leading path components should be
* stripped from paths obtained from the patch. It is an error if a
* negative strip count is passed.
*
* If @a reverse is @c TRUE, apply patches in reverse, deleting lines
* the patch would add and adding lines the patch would delete.
*
* If @a ignore_whitespace is TRUE, allow patches to be applied if they
* only differ from the target by whitespace.
*
* If @a remove_tempfiles is TRUE, lifetimes of temporary files created
* during patching will be managed internally. Otherwise, the caller should
* take ownership of these files, the names of which can be obtained by
* passing a @a patch_func callback.
*
* If @a patch_func is non-NULL, invoke @a patch_func with @a patch_baton
* for each patch target processed.
*
* If @a ctx->notify_func2 is non-NULL, invoke @a ctx->notify_func2 with
* @a ctx->notify_baton2 as patching progresses.
*
* If @a ctx->cancel_func is non-NULL, invoke it passing @a
* ctx->cancel_baton at various places during the operation.
*
* Use @a scratch_pool for temporary allocations.
*
* @since New in 1.7.
*/
svn_error_t *
svn_client_patch(const char *patch_abspath,
const char *wc_dir_abspath,
svn_boolean_t dry_run,
int strip_count,
svn_boolean_t reverse,
svn_boolean_t ignore_whitespace,
svn_boolean_t remove_tempfiles,
svn_client_patch_func_t patch_func,
void *patch_baton,
svn_client_ctx_t *ctx,
apr_pool_t *scratch_pool);
/** @} */
/** @} end group: Client working copy management */
/**
*
* @defgroup clnt_sessions Client session related functions
*
* @{
*
*/
( run in 0.564 second using v1.01-cache-2.11-cpan-524268b4103 )