Index: subversion/include/svn_transform_rule.h =================================================================== --- subversion/include/svn_transform_rule.h (revision 0) +++ subversion/include/svn_transform_rule.h (revision 0) @@ -0,0 +1,82 @@ +/** + * @copyright + * ==================================================================== + * Copyright (c) 2000-2004 CollabNet. All rights reserved. + * + * This software is licensed as described in the file COPYING, which + * you should have received as part of this distribution. The terms + * are also available at http://subversion.tigris.org/license-1.html. + * If newer versions of this license are posted there, you may use a + * newer version instead, at your option. + * + * This software consists of voluntary contributions made by many + * individuals. For exact contribution history, see the revision + * history and logs, available at http://subversion.tigris.org/. + * ==================================================================== + * @endcopyright + * + * @file svn_transform_rule.h + * @brief A transform rule manipulation library + * + * This library is used to handle reading of transform rules + * from config files, and applying the rules to paths. + */ + +#ifndef SVN_TRANSFORM_RULE_H +#define SVN_TRANSFORM_RULE_H + + +#include +#include +#include +#include + +#include "svn_string.h" +#include "svn_error.h" + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +typedef struct transform_rule +{ + const char *match; + const char *replacement; + int priority; +} svn_transform_rule_t; + + +/** Transform rule reading + * + * defgroup svn_transform_rule_read_stuff Transform rule reading + * @{ + */ + +/** Read transform rules from the config file into @a rules. */ +svn_error_t *svn_transform_rule_read_from_config (apr_array_header_t **rules, + apr_pool_t *pool); + +/** @} */ + +/** Transform rule processing + * + * defgroup svn_transform_rule_process Transform rule processing + * @{ + */ + +/* Process @a input using transform rules in @rules and put the + result in @a *ouput. */ +svn_error_t *svn_transform_rule_processy (apr_array_header_t *rules, + const char *input, + svn_stringbuf_t **result, + apr_pool_t *pool); + + +/** @} */ + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* SVN_TRANSFORM_RULE_H */ Index: subversion/include/svn_config.h =================================================================== --- subversion/include/svn_config.h (revision 17211) +++ subversion/include/svn_config.h (working copy) @@ -90,6 +90,7 @@ typedef struct svn_config_t svn_config_t #define SVN_CONFIG_OPTION_NO_UNLOCK "no-unlock" #define SVN_CONFIG_SECTION_TUNNELS "tunnels" #define SVN_CONFIG_SECTION_AUTO_PROPS "auto-props" +#define SVN_CONFIG_SECTION_TRANSFORM_RULES "transform-rules" /** @} */ /** @name Repository conf directory configuration files strings Index: subversion/include/svn_client.h =================================================================== --- subversion/include/svn_client.h (revision 17211) +++ subversion/include/svn_client.h (working copy) @@ -627,6 +627,10 @@ typedef struct svn_client_ctx_t /** Callback baton for progress_func. * @since New in 1.3. */ void *progress_baton; + + /** Transform rules. + * @since New in 1.4. */ + apr_array_header_t *transform_rules; } svn_client_ctx_t; Index: subversion/include/svn_opt.h =================================================================== --- subversion/include/svn_opt.h (revision 17211) +++ subversion/include/svn_opt.h (working copy) @@ -28,6 +28,7 @@ #include "svn_types.h" #include "svn_error.h" +#include "svn_config.h" #ifdef __cplusplus extern "C" { @@ -264,6 +265,30 @@ int svn_opt_parse_revision (svn_opt_revi * auto-escaping. On each local path, canonicalize case and path * separators, and silently skip it if it has the same name as a * Subversion working copy administrative directory. + * Also perform transform rule processing on each URL + * + * + * Allocate @a *targets_p and its elements in @a pool. + * + * @since New in 1.4. + */ +svn_error_t * +svn_opt_args_to_target_array3 (apr_hash_t *config, + apr_array_header_t **targets_p, + apr_getopt_t *os, + apr_array_header_t *known_targets, + apr_pool_t *pool); + +/** + * Pull remaining target arguments from @a os into @a *targets_p, + * converting them to UTF-8, followed by targets from @a known_targets + * (which might come from, for example, the "--targets" command line + * option), which are already in UTF-8. + * + * On each URL target, do some IRI-to-URI encoding and some + * auto-escaping. On each local path, canonicalize case and path + * separators, and silently skip it if it has the same name as a + * Subversion working copy administrative directory. * * Allocate @a *targets_p and its elements in @a pool. * Index: subversion/libsvn_subr/transform_rule.c =================================================================== --- subversion/libsvn_subr/transform_rule.c (revision 0) +++ subversion/libsvn_subr/transform_rule.c (revision 0) @@ -0,0 +1,191 @@ +/* + * transform_rule.c: Rules for transforming URL and other syntax + * + * ==================================================================== + * Copyright (c) 2000-2004 CollabNet. All rights reserved. + * + * This software is licensed as described in the file COPYING, which + * you should have received as part of this distribution. The terms + * are also available at http://subversion.tigris.org/license-1.html. + * If newer versions of this license are posted there, you may use a + * newer version instead, at your option. + * + * This software consists of voluntary contributions made by many + * individuals. For exact contribution history, see the revision + * history and logs, available at http://subversion.tigris.org/. + * ==================================================================== + */ + + + +#define APR_WANT_STRFUNC +#define APR_WANT_MEMFUNC +#include + +#include +#include +#include "svn_types.h" +#include "svn_error.h" +#include "svn_pools.h" +#include "svn_config.h" +#include "svn_transform_rule.h" +#include "svn_private_config.h" + +struct rg_baton +{ + apr_array_header_t **rules; + apr_pool_t *pool; +}; + +static svn_boolean_t +rule_getter (const char *name, const char *value, void *baton, + apr_pool_t *pool) +{ + struct rg_baton *rg = baton; + svn_transform_rule_t new_rule; + int replacement_len; + const char *priority; + char *replacement; + + new_rule.match = apr_pstrdup (rg->pool, name); + replacement = apr_pstrdup (rg->pool, value); + replacement_len = strlen (replacement) - 1; + + while (replacement_len > 0 && replacement[replacement_len] != ' ') + replacement_len--; + + /* Really want to return an error here. */ + if (replacement_len <= 0) + return TRUE; + + priority = &replacement[replacement_len + 1]; + new_rule.priority = atoi (priority); + replacement[replacement_len] = '\0'; + new_rule.replacement = replacement; + + APR_ARRAY_PUSH(*(rg->rules),svn_transform_rule_t) = new_rule; + + return TRUE; +} + +static int +compare_rules (const void *a, const void *b) +{ + const svn_transform_rule_t *first = a; + const svn_transform_rule_t *second = b; + + return first->priority - second->priority; +} + +svn_error_t * +svn_transform_rule_get_from_config (apr_array_header_t **rules, + apr_hash_t *config, + apr_pool_t *pool) +{ + svn_config_t *cfg; + struct rg_baton baton; + + *rules = NULL; + + cfg = apr_hash_get (config, SVN_CONFIG_CATEGORY_CONFIG, + strlen (SVN_CONFIG_CATEGORY_CONFIG)); + if (cfg) + { + *rules = apr_array_make (pool, 1, sizeof (svn_transform_rule_t)); + baton.rules = rules; + baton.pool = pool; + svn_config_enumerate2 (cfg, SVN_CONFIG_SECTION_TRANSFORM_RULES, + rule_getter, &baton, pool); + qsort ((*rules)->elts, (*rules)->nelts, sizeof (svn_transform_rule_t), + compare_rules); + } + return SVN_NO_ERROR; +} + +static svn_error_t * +svn_transform_rule_process_one (svn_transform_rule_t *rule, + const char *string, + svn_stringbuf_t **result, + apr_pool_t *pool) +{ + const char *haystack = string; + const char *spot; + unsigned int startsub; + unsigned int endsub; + int replpos = 0; + const char *repl = rule->replacement; + + spot = strstr (haystack, rule->match); + + if (spot == NULL) + { + *result = svn_stringbuf_create (string, pool); + return SVN_NO_ERROR; + } + + *result = svn_stringbuf_create ("", pool); + + startsub = spot - string; + endsub = startsub + strlen (rule->match); + spot = string + endsub; + svn_stringbuf_appendbytes (*result, string, startsub); + + while (repl[replpos] != '\0') + { + if (repl[replpos] == '$' + && repl[replpos+1] >= '0' + && repl[replpos+1] <= '9' + && spot[0] == '#') + { + spot++; + endsub++; + while (spot && spot[0] != '\0' && spot[0] != '/' && spot[0] != '#') + { + svn_stringbuf_appendbytes (*result, &spot[0], 1); + spot++; + endsub++; + } + replpos++; + } + else + { + svn_stringbuf_appendbytes (*result, &repl[replpos], 1); + } + replpos++; + } + svn_stringbuf_appendbytes (*result, &string[endsub], + strlen(string) - endsub); + + return SVN_NO_ERROR; +} + +svn_error_t * +svn_transform_rule_process (apr_array_header_t *rules, + const char *string, + svn_stringbuf_t **result, + apr_pool_t *pool) +{ + int i; + const char *startplace; + svn_stringbuf_t *before, *after; + + startplace = strstr (string, "rule://"); + if (startplace == NULL) + { + *result = svn_stringbuf_create (string, pool); + return SVN_NO_ERROR; + } + before = svn_stringbuf_create (string + strlen ("rule://"), pool); + for (i = 0; i < rules->nelts; i++) + { + svn_transform_rule_t rule; + + rule = APR_ARRAY_IDX (rules, i, svn_transform_rule_t); + SVN_ERR(svn_transform_rule_process_one (&rule, before->data, + &after, pool)); + before = after; + } + *result = before; + return SVN_NO_ERROR; + +} Index: subversion/libsvn_subr/opt.c =================================================================== --- subversion/libsvn_subr/opt.c (revision 17211) +++ subversion/libsvn_subr/opt.c (working copy) @@ -548,17 +548,23 @@ svn_opt_parse_path (svn_opt_revision_t * svn_error_t * -svn_opt_args_to_target_array2 (apr_array_header_t **targets_p, - apr_getopt_t *os, - apr_array_header_t *known_targets, - apr_pool_t *pool) +svn_opt_args_to_target_array_internal (apr_hash_t *config, + apr_array_header_t **targets_p, + apr_getopt_t *os, + apr_array_header_t *known_targets, + svn_boolean_t do_translate, + apr_pool_t *pool) { int i; + apr_array_header_t *rules; apr_array_header_t *input_targets = apr_array_make (pool, DEFAULT_ARRAY_SIZE, sizeof (const char *)); apr_array_header_t *output_targets = apr_array_make (pool, DEFAULT_ARRAY_SIZE, sizeof (const char *)); + if (config && do_translate) + svn_transform_rule_get_from_config (&rules, config, pool); + /* Step 1: create a master array of targets that are in UTF-8 encoding, and come from concatenating the targets left by apr_getopt, plus any extra targets (e.g., from the --targets switch.) */ @@ -594,6 +600,13 @@ svn_opt_args_to_target_array2 (apr_array /* URLs and wc-paths get treated differently. */ if (svn_path_is_url (utf8_target)) { + if (do_translate) + { + svn_stringbuf_t *result; + svn_transform_rule_process (rules, utf8_target, &result, + pool); + utf8_target = result->data; + } /* No need to canonicalize a URL's case or path separators. */ /* Convert to URI. */ @@ -673,6 +686,29 @@ svn_opt_args_to_target_array2 (apr_array return SVN_NO_ERROR; } +svn_error_t * +svn_opt_args_to_target_array3 (apr_hash_t *config, + apr_array_header_t **targets_p, + apr_getopt_t *os, + apr_array_header_t *known_targets, + apr_pool_t *pool) +{ + return svn_opt_args_to_target_array_internal (config, targets_p, os, + known_targets, TRUE, + pool); +} + +svn_error_t * +svn_opt_args_to_target_array2 (apr_array_header_t **targets_p, + apr_getopt_t *os, + apr_array_header_t *known_targets, + apr_pool_t *pool) +{ + return svn_opt_args_to_target_array_internal (NULL, targets_p, os, + known_targets, FALSE, + pool); +} + svn_error_t * svn_opt_args_to_target_array (apr_array_header_t **targets_p, Index: subversion/clients/cmdline/merge-cmd.c =================================================================== --- subversion/clients/cmdline/merge-cmd.c (revision 17211) +++ subversion/clients/cmdline/merge-cmd.c (working copy) @@ -63,7 +63,7 @@ svn_cl__merge (apr_getopt_t *os, using_alternate_syntax = TRUE; } - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* If there are no targets at all, then let's just give the user a Index: subversion/clients/cmdline/checkout-cmd.c =================================================================== --- subversion/clients/cmdline/checkout-cmd.c (revision 17211) +++ subversion/clients/cmdline/checkout-cmd.c (working copy) @@ -70,7 +70,7 @@ svn_cl__checkout (apr_getopt_t *os, const char *repos_url; int i; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* If there are no targets at all, then let's just give the user a Index: subversion/clients/cmdline/propdel-cmd.c =================================================================== --- subversion/clients/cmdline/propdel-cmd.c (revision 17211) +++ subversion/clients/cmdline/propdel-cmd.c (working copy) @@ -53,7 +53,7 @@ svn_cl__propdel (apr_getopt_t *os, SVN_ERR (svn_utf_cstring_to_utf8 (&pname_utf8, pname, pool)); /* Suck up all the remaining arguments into a targets array */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 file arguments */ Index: subversion/clients/cmdline/move-cmd.c =================================================================== --- subversion/clients/cmdline/move-cmd.c (revision 17211) +++ subversion/clients/cmdline/move-cmd.c (working copy) @@ -45,7 +45,7 @@ svn_cl__move (apr_getopt_t *os, svn_commit_info_t *commit_info = NULL; svn_error_t *err; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (targets->nelts != 2) Index: subversion/clients/cmdline/mkdir-cmd.c =================================================================== --- subversion/clients/cmdline/mkdir-cmd.c (revision 17211) +++ subversion/clients/cmdline/mkdir-cmd.c (working copy) @@ -46,7 +46,7 @@ svn_cl__mkdir (apr_getopt_t *os, svn_commit_info_t *commit_info = NULL; svn_error_t *err; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (! targets->nelts) Index: subversion/clients/cmdline/cat-cmd.c =================================================================== --- subversion/clients/cmdline/cat-cmd.c (revision 17211) +++ subversion/clients/cmdline/cat-cmd.c (working copy) @@ -43,7 +43,7 @@ svn_cl__cat (apr_getopt_t *os, svn_stream_t *out; apr_pool_t *subpool = svn_pool_create (pool); - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Cat cannot operate on an implicit '.' so a filename is required */ Index: subversion/clients/cmdline/revert-cmd.c =================================================================== --- subversion/clients/cmdline/revert-cmd.c (revision 17211) +++ subversion/clients/cmdline/revert-cmd.c (working copy) @@ -42,7 +42,7 @@ svn_cl__revert (apr_getopt_t *os, apr_array_header_t *targets; svn_error_t *err; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Revert has no implicit dot-target `.', so don't you put that code here! */ Index: subversion/clients/cmdline/diff-cmd.c =================================================================== --- subversion/clients/cmdline/diff-cmd.c (revision 17211) +++ subversion/clients/cmdline/diff-cmd.c (working copy) @@ -44,6 +44,7 @@ svn_cl__diff (apr_getopt_t *os, apr_pool_t *pool) { svn_cl__opt_state_t *opt_state = ((svn_cl__cmd_baton_t *) baton)->opt_state; + svn_client_ctx_t *ctx = ((svn_cl__cmd_baton_t *) baton)->ctx; apr_array_header_t *options; apr_array_header_t *targets; apr_file_t *outfile, *errfile; @@ -66,7 +67,7 @@ svn_cl__diff (apr_getopt_t *os, if ((status = apr_file_open_stderr (&errfile, pool))) return svn_error_wrap_apr (status, _("Can't open stderr")); - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (! opt_state->old_target && ! opt_state->new_target Index: subversion/clients/cmdline/copy-cmd.c =================================================================== --- subversion/clients/cmdline/copy-cmd.c (revision 17211) +++ subversion/clients/cmdline/copy-cmd.c (working copy) @@ -46,7 +46,7 @@ svn_cl__copy (apr_getopt_t *os, svn_commit_info_t *commit_info = NULL; svn_error_t *err; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (targets->nelts != 2) return svn_error_create (SVN_ERR_CL_ARG_PARSING_ERROR, 0, NULL); Index: subversion/clients/cmdline/ls-cmd.c =================================================================== --- subversion/clients/cmdline/ls-cmd.c (revision 17211) +++ subversion/clients/cmdline/ls-cmd.c (working copy) @@ -280,7 +280,7 @@ svn_cl__ls (apr_getopt_t *os, apr_pool_t *subpool = svn_pool_create (pool); apr_uint32_t dirent_fields; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments */ Index: subversion/clients/cmdline/blame-cmd.c =================================================================== --- subversion/clients/cmdline/blame-cmd.c (revision 17211) +++ subversion/clients/cmdline/blame-cmd.c (working copy) @@ -177,7 +177,7 @@ svn_cl__blame (apr_getopt_t *os, int i; svn_boolean_t is_head_or_base = FALSE; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Blame needs a file on which to operate. */ Index: subversion/clients/cmdline/propget-cmd.c =================================================================== --- subversion/clients/cmdline/propget-cmd.c (revision 17211) +++ subversion/clients/cmdline/propget-cmd.c (working copy) @@ -74,7 +74,7 @@ svn_cl__propget (apr_getopt_t *os, SVN_ERR (svn_utf_cstring_to_utf8 (&pname_utf8, pname, pool)); /* suck up all the remaining arguments into a targets array */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 file arguments */ Index: subversion/clients/cmdline/log-cmd.c =================================================================== --- subversion/clients/cmdline/log-cmd.c (revision 17211) +++ subversion/clients/cmdline/log-cmd.c (working copy) @@ -390,7 +390,7 @@ svn_cl__log (apr_getopt_t *os, const char *target; int i; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments */ Index: subversion/clients/cmdline/update-cmd.c =================================================================== --- subversion/clients/cmdline/update-cmd.c (revision 17211) +++ subversion/clients/cmdline/update-cmd.c (working copy) @@ -41,7 +41,7 @@ svn_cl__update (apr_getopt_t *os, svn_client_ctx_t *ctx = ((svn_cl__cmd_baton_t *) baton)->ctx; apr_array_header_t *targets; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments */ Index: subversion/clients/cmdline/resolved-cmd.c =================================================================== --- subversion/clients/cmdline/resolved-cmd.c (revision 17211) +++ subversion/clients/cmdline/resolved-cmd.c (working copy) @@ -46,7 +46,7 @@ svn_cl__resolved (apr_getopt_t *os, int i; apr_pool_t *subpool; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (! targets->nelts) return svn_error_create (SVN_ERR_CL_ARG_PARSING_ERROR, 0, NULL); Index: subversion/clients/cmdline/cleanup-cmd.c =================================================================== --- subversion/clients/cmdline/cleanup-cmd.c (revision 17211) +++ subversion/clients/cmdline/cleanup-cmd.c (working copy) @@ -43,7 +43,7 @@ svn_cl__cleanup (apr_getopt_t *os, apr_pool_t *subpool; int i; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments */ Index: subversion/clients/cmdline/commit-cmd.c =================================================================== --- subversion/clients/cmdline/commit-cmd.c (revision 17211) +++ subversion/clients/cmdline/commit-cmd.c (working copy) @@ -48,7 +48,7 @@ svn_cl__commit (apr_getopt_t *os, svn_boolean_t no_unlock = FALSE; svn_commit_info_t *commit_info = NULL; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments. */ Index: subversion/clients/cmdline/add-cmd.c =================================================================== --- subversion/clients/cmdline/add-cmd.c (revision 17211) +++ subversion/clients/cmdline/add-cmd.c (working copy) @@ -45,7 +45,7 @@ svn_cl__add (apr_getopt_t *os, int i; apr_pool_t *subpool; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (! targets->nelts) Index: subversion/clients/cmdline/propset-cmd.c =================================================================== --- subversion/clients/cmdline/propset-cmd.c (revision 17211) +++ subversion/clients/cmdline/propset-cmd.c (working copy) @@ -85,7 +85,7 @@ svn_cl__propset (apr_getopt_t *os, _("Bad encoding option: prop value not stored as UTF8")); /* Suck up all the remaining arguments into a targets array */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (opt_state->revprop) /* operate on a revprop */ Index: subversion/clients/cmdline/switch-cmd.c =================================================================== --- subversion/clients/cmdline/switch-cmd.c (revision 17211) +++ subversion/clients/cmdline/switch-cmd.c (working copy) @@ -96,7 +96,7 @@ svn_cl__switch (apr_getopt_t *os, /* This command should discover (or derive) exactly two cmdline arguments: a local path to update ("target"), and a new url to switch to ("switch_url"). */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* handle only-rewrite case specially */ Index: subversion/clients/cmdline/delete-cmd.c =================================================================== --- subversion/clients/cmdline/delete-cmd.c (revision 17211) +++ subversion/clients/cmdline/delete-cmd.c (working copy) @@ -44,7 +44,7 @@ svn_cl__delete (apr_getopt_t *os, svn_commit_info_t *commit_info = NULL; svn_error_t *err; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (! targets->nelts) Index: subversion/clients/cmdline/import-cmd.c =================================================================== --- subversion/clients/cmdline/import-cmd.c (revision 17211) +++ subversion/clients/cmdline/import-cmd.c (working copy) @@ -73,7 +73,7 @@ svn_cl__import (apr_getopt_t *os, * ### kff todo: review above behaviors. */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (targets->nelts < 1) Index: subversion/clients/cmdline/proplist-cmd.c =================================================================== --- subversion/clients/cmdline/proplist-cmd.c (revision 17211) +++ subversion/clients/cmdline/proplist-cmd.c (working copy) @@ -46,7 +46,7 @@ svn_cl__proplist (apr_getopt_t *os, int i; /* Suck up all remaining args in the target array. */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments */ Index: subversion/clients/cmdline/export-cmd.c =================================================================== --- subversion/clients/cmdline/export-cmd.c (revision 17211) +++ subversion/clients/cmdline/export-cmd.c (working copy) @@ -46,7 +46,7 @@ svn_cl__export (apr_getopt_t *os, svn_opt_revision_t peg_revision; const char *truefrom; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* We want exactly 1 or 2 targets for this subcommand. */ Index: subversion/clients/cmdline/status-cmd.c =================================================================== --- subversion/clients/cmdline/status-cmd.c (revision 17211) +++ subversion/clients/cmdline/status-cmd.c (working copy) @@ -159,7 +159,7 @@ svn_cl__status (apr_getopt_t *os, struct status_baton sb; svn_revnum_t repos_rev = SVN_INVALID_REVNUM; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* We want our -u statuses to be against HEAD. */ Index: subversion/clients/cmdline/propedit-cmd.c =================================================================== --- subversion/clients/cmdline/propedit-cmd.c (revision 17211) +++ subversion/clients/cmdline/propedit-cmd.c (working copy) @@ -57,7 +57,7 @@ svn_cl__propedit (apr_getopt_t *os, SVN_ERR (svn_utf_cstring_to_utf8 (&pname_utf8, pname, pool)); /* Suck up all the remaining arguments into a targets array */ - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); if (opt_state->revprop) /* operate on a revprop */ Index: subversion/clients/cmdline/lock-cmd.c =================================================================== --- subversion/clients/cmdline/lock-cmd.c (revision 17211) +++ subversion/clients/cmdline/lock-cmd.c (working copy) @@ -84,7 +84,7 @@ svn_cl__lock (apr_getopt_t *os, apr_array_header_t *targets; const char *comment; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* We only support locking files, so '.' is not valid. */ Index: subversion/clients/cmdline/info-cmd.c =================================================================== --- subversion/clients/cmdline/info-cmd.c (revision 17211) +++ subversion/clients/cmdline/info-cmd.c (working copy) @@ -452,7 +452,7 @@ svn_cl__info (apr_getopt_t *os, svn_error_t *err; svn_opt_revision_t peg_revision; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* Add "." if user passed 0 arguments. */ Index: subversion/clients/cmdline/unlock-cmd.c =================================================================== --- subversion/clients/cmdline/unlock-cmd.c (revision 17211) +++ subversion/clients/cmdline/unlock-cmd.c (working copy) @@ -43,7 +43,7 @@ svn_cl__unlock (apr_getopt_t *os, svn_client_ctx_t *ctx = ((svn_cl__cmd_baton_t *) baton)->ctx; apr_array_header_t *targets; - SVN_ERR (svn_opt_args_to_target_array2 (&targets, os, + SVN_ERR (svn_opt_args_to_target_array3 (ctx->config, &targets, os, opt_state->targets, pool)); /* We don't support unlock on directories, so "." is not relevant. */