Checkout Tools
  • last updated 8 hours ago
Constraints: committers
Constraints: files
Constraints: dates

Changeset 1497266 is being indexed.

Add a new --remove-ignored option to 'svn cleanup', replacing --no-ignore.

Previously, --no-ignore was only valid with --remove-unversioned. The new

--remove-ignored option allows removing ignored items separately from

non-ignored unversioned items.

Suggested by: gstein

* subversion/include/svn_client.h

(svn_client_cleanup2): Rename 'no_ignore' parameter to


* subversion/libsvn_client/cleanup.c

(remove_unversioned_items_baton): Add 'remove_unversioned_items' member.

(remove_unversioned_items): Only remove unversioned items if the

'remove_unversioned_items' is set in the baton.

(svn_client_cleanup2): Account for renamed parameter and new baton member.

Run the delete-items status walk if either unversioned or ignored items

are to be removed, not just for unversioned items.

* subversion/svn/cl.h

(svn_cl__opt_state_t): Add remove_ignored.

* subversion/svn/cleanup-cmd.c

(svn_cl__cleanup): Replace handling of --no-ignore with --remove-ignored.

* subversion/svn/svn.c

(svn_cl__longopt_t): Add opt_remove_ignored.

(svn_cl__options): Add --remove-ignored.

(svn_cl__cmd_table): Adjust 'svn help cleanup' output.

(sub_main): Handle --remove-ignored.

* subversion/tests/cmdline/

(cleanup_unversioned_items): Replace --no-ignore with --remove-ignored.

  1. … 5 more files in changeset.
Allow 'svn cleanup' to remove unversioned items from the working copy.

This should address the feature request from issue #3549.

Add two new options to 'svn cleanup', --remove-unversioned and --no-ignore.

The former causes unversioned files and directories to be removed after

successful cleanup. The latter causes ignored items to be removed as well.

One remaining question is what to do with externals. Right now, 'svn cleanup'

never recurses into externals. Should it recurse into externals if the

--remove-unversioned option is given? Should we change it to always recurse

into externals by default? I'm not quite sure.

* subversion/include/svn_client.h

(svn_client_cleanup2): Declare.

(svn_client_cleanup): Deprecate.

* subversion/libsvn_client/cleanup.c

(remove_unversioned_items): New helper function.

(svn_client_cleanup2): Implement as an extension of svn_client_cleanup(),

which can optionally remove unversioned items after all other cleanup

actions, via a status walk.

* subversion/libsvn_client/deprecated.c

(svn_client_cleanup): Implement as a wrapper around svn_client_cleanup2().

* subversion/svn/cl.h

(svn_cl__opt_state_t): Add new 'remove_unversioned' option.

* subversion/svn/cleanup-cmd.c

(svn_cl__cleanup): Run svn_client_cleanup2() to support removal of

unversioned items. Reject --no-ignore option without --remove-unversioned.

* subversion/svn/svn.c

(svn_cl__longopt_t): Add opt_remove_unversioned.

(svn_cl__options): Add --remove-unversioned option.

(svn_cl__cmd_table): Extend help text of 'svn cleanup'.

(sub_main): Handle --remove-unversioned option.

* subversion/tests/cmdline/

(cleanup_unversioned_items, test_list): New test.

  1. … 6 more files in changeset.
Follow-up to 1489203: Remove unnecessary check for branches ancestry from

command line client. All required checks are performed in libsvn_client.

* subversion/svn/cl.h

* subversion/svn/util.c

(svn_cl__check_related_source_and_target): Remove

* subversion/svn/merge-cmd.c

* subversion/svn/mergeinfo-cmd.c

(run_merge, svn_cl__mergeinfo): Remove call to


  1. … 3 more files in changeset.
Implement '--log' option for 'svn mergeinfo --show-revs' subcommand to print

revisions log message, author and date.

Suggested by: lgo

* subversion/svn/cl.h

(svn_cl__opt_state_t): Add mergeinfo_log member.

* subversion/svn/mergeinfo-cmd.c

(): Include svn_compat.h and svn_props.h.

(SEP_STRING, print_log_details): New.

(mergeinfo_log): New, mostly extracted from svn_cl__mergeinfo().

(svn_cl__mergeinfo): Call mergeinfo_log().

* subversion/svn/svn.c

(svn_cl__longopt_t): Add opt_mergeinfo_log.

(svn_cl__options): Add description for '--log' option.

(svn_cl__cmd_table): Add opt_mergeinfo_log to mergeinfo subcommand.

(sub_main): Handle '--log' option.

* subversion/tests/cmdline/

(mergeinfo_log): New test.

(test_list): Add mergeinfo_log.

  1. … 3 more files in changeset.
Fix non-ASCII character handling in several 'svn' command-line options, when

using a non-UTF-8 locale. In roughly decreasing order of importance:

--old, --new:

It did not convert the path to UTF-8. It would fail to find a non-ASCII

path, or conceivably could find the wrong path.

--search, --search-and:

It did not convert the search term to UTF-8. It would fail to match a

non-ASCII search term, or conceivably could find a wrong match.


The check for accidentally specifying a versioned file used the

unconverted path, and so a non-ASCII path would (most likely) not

trigger the check when it should.

--limit, --accept, --show-revs, --strip, --change:

It did not convert the value to UTF-8 before parsing it. Valid values

would work properly, but the error message displayed for an invalid

value would display the invalid value wrongly.


Conversion to UTF-8 has been moved before comparison against fixed ASCII

strings like 'CRLF'. This will only make a difference if there are

character encodings in use that are not compatible with ASCII; otherwise

it is just for consistency of coding style.

* subversion/svn/svn.c

(sub_main): Convert option arguments to UTF-8 before using them, in most

cases where we weren't already doing so.

* subversion/svn/cl.h

(svn_cl__opt_state_t): Document which fields are *not* converted to UTF-8,

instead of the previous incomplete annotation of which ones are. Remove

the unused 'changelist' field (which was long ago superseded by the

'changelists' array.

  1. … 1 more file in changeset.
Make 'svn' print a summary of conflicts before starting interactive

conflict resolution, as well as after resolution is finished, to give the

user an idea of how much resolution work will be needed.

Addresses issue #3497, "auto merge as much as can; then print summary, then

go into conflict resolution".

* subversion/svn/cl.h,


(svn_cl__notifier_print_conflict_stats): Rewrite as a wrapper ...

(svn_cl__print_conflict_stats): ... around this new function.

* subversion/svn/conflict-callbacks.c

(svn_cl__interactive_conflict_baton): Add a flag to remember whether we

have printed the summary yet.

(svn_cl__get_conflict_func_interactive_baton): Initialize that flag.

(conflict_func_interactive): Print a summary of conflicts before starting

interactive resolution.

  1. … 2 more files in changeset.
Fix a bug in the Summary of Conflicts when using interactive conflict

resolution. Marking a text conflict as resolved but leaving a prop conflict

unresolved on the same file, or vice versa, would decrement both the text

and prop conflict summary stats.

Found by: Mattias Engdegård <mattiase{_AT_}>

* subversion/svn/cl.h

(svn_cl__conflict_stats_t): New structure type.


svn_cl__conflict_stats_resolved): New functions.


svn_cl__get_notifier): Take 'conflict_stats' as a parameter.

* subversion/svn/conflict-callbacks.c

(svn_cl__interactive_conflict_baton_t): Add a 'conflict_stats' field.

(svn_cl__get_conflict_func_interactive_baton): Initialize the new field.

(conflict_func_interactive): New function, containing what was the

body of svn_cl__conflict_func_interactive().

(svn_cl__conflict_func_interactive): Re-write as a wrapper, and adjust

the conflict stats if conflict_func_interactive() returns a value that

means the conflict will be marked as resolved.

* subversion/svn/notify.c

(notify_baton): Replace the separate conflict stats fields with a

pointer to a conflict stats structure.

(svn_cl__conflict_stats_t): New structure definition.


svn_cl__notifier_print_conflict_stats): Adjust for the extra level of

indirection in notify_baton.

(notify): The same, and don't adjust the conflict stats when handling

a 'resolved' notification.

(svn_cl__get_notifier): Adjust to take the conflict stats as a parameter

instead of initializing the stats here.

* subversion/svn/svn.c

(sub_main): Create a conflict stats structure here and pass it along when

getting the notifier and when getting the conflict resolver callback.

  1. … 3 more files in changeset.
Remove some unused code in 'svn'.

* subversion/svn/cl.h,


(svn_cl__notifier_reset_conflict_stats): Delete this unused function.

* subversion/svn/resolve-cmd.c

(svn_cl__resolve): Don't re-install the conflict resolver callback, since

the one and only callback is already installed.

  1. … 2 more files in changeset.
Improve error messages on propset and propedit when an svn: property

is misspelled.

* subversion/svn/cl.h (svn_cl__prop_use_t): New enumeration.

(svn_cl__check_svn_prop_name): Add prop_use parameter.

* subversion/svn/props.c (force_prop_option_message, wrong_prop_error_message):

Two new helper functions that return a customized error message based

on svn_cl__prop_use_t property use discriminator.

(svn_cl__check_svn_prop_name): Update prototype with prop_use.

Call the helpers to generate customized error messages based on the

given property use.

* subversion/svn/propset-cmd.c (svn_cl__propset): Set property usage.

* subversion/svn/propedit-cmd.c (svn_cl__propedit): Set property usage.

  1. … 3 more files in changeset.
Make the command client use a wrapper function when calling a deprecated

function to avoid a compiler warning.

* subversion/svn/cl.h

(svn_cl__deprecated_merge_reintegrate): New.

* subversion/svn/deprecated.c: New file.

* subversion/svn/merge-cmd.c

(run_merge): Use wrapper.

  1. … 2 more files in changeset.
Make 'update' and 'switch' libsvn_client APIs delay calling the conflict

resolver for each conflicted path until the whole update is complete, like

r1459012 did for merge. Previously, the APIs called the callback as soon as

each conflict is raised, and 'svn' used a work-around.


- Avoids the possibility of a network timeout if the resolver callback

takes a long time, for example when doing interactive resolution.

- Means that all changes have been received. This is important when

resolving a tree conflict that involves a copy or move, because the

resolver (code or human) may need to look at or modify another path.

- Makes all subcommands work the same way. Eliminates the code in

'svn' that implements a 'postpone' callback.

- Makes this way of working available to all clients. Makes no difference

to a client that does not want to use it, such as a GUI.

This changes the notifications printed by 'svn' in the case of pre-specified

resolution (--accept=xxx), in the same way as described in r1459012 for

'merge'. It now prints a notification with status 'C' for each conflicted

path, and then later a 'Resolved ...' line for each conflicted path. The

Summary of Conflicts now reports both the number of remaining conflicts and

the number of resolved conflicts.

* subversion/libsvn_client/client.h


(svn_client__resolve_conflicts): New function, moved and renamed from

resolve_conflicts() in merge.c, with the list-of-paths parameter changed

to a simple hash and the 'resolved' output made optional.

* subversion/libsvn_client/merge.c

(resolve_conflicts): Move to resolved.c: svn_client__resolve_conflicts().

(do_merge): Track the change of resolve_conflicts().

* subversion/libsvn_client/update.c

(record_conflict): New function.

(update_internal): Don't use the resolver callback in the client context,

but instead use a local one that just remembers the conflicted paths.

(svn_client__update_internal): Call the resolver on the conflicted paths

before returning.

* subversion/libsvn_client/switch.c



svn_client__switch_internal): Same as in update.c.

* subversion/svn/cl.h,





svn_cl__resolve_postponed_conflicts): Delete.

* subversion/svn/svn.c

(sub_main): Install the proper conflict handler instead of the 'postpone'


* subversion/svn/merge-cmd.c

(svn_cl__merge): Don't install the conflict handler here, as we've now

done it in 'svn'.

* subversion/svn/update-cmd.c

(svn_cl__update): Remove a comment that said we were using the 'postpone'

handler. Don't resolve conflicts after the operation.

* subversion/svn/switch-cmd.c

(svn_cl__switch): Same.

* subversion/tests/cmdline/


update_output_with_conflicts_resolved): Adjust to expect the new

placement of the 'Resolved conflicts ...' line and the new form of the

summary of conflicts.

  1. … 11 more files in changeset.
Align comments for easier reading.


(svn_cl__opt_state_t): Align comments.

Approved by: danielsh

* subversion/svn/cl.h,


(svn_cl__conflict_func_interactive): Move all of the documentation to the


  1. … 1 more file in changeset.
Let svn_cl__resolve_postponed_conflicts() tell the caller whether it

resolved all the conflicts. We don't use that yet, but we will soon. And

some other small tweaks the 'svn' conflict notification code.

* subversion/svn/cl.h,

(svn_cl__resolve_postponed_conflicts): Return a flag indicating whether

all conflicts were resolved.

(svn_cl__notifier_reset_conflict_stats): New function.

(svn_cl__print_conflict_stats): Rename to

svn_cl__notifier_print_conflict_stats() and s/pool/scratch_pool/ and

s/notify_baton/baton/ (the last being a follow-up to r1446746.

* subversion/svn/conflict-callbacks.c

(get_postponed_conflicted_paths): Simplify: remove a special-case return.

(svn_cl__resolve_postponed_conflicts): Implement the extra parameter, and

remove the special-case return.

* subversion/svn/notify.c

(svn_cl__notifier_reset_conflict_stats): New function.

(svn_cl__print_conflict_stats): Rename to

svn_cl__notifier_print_conflict_stats() and s/pool/scratch_pool/.

* subversion/svn/merge-cmd.c

(svn_cl__merge): Update calls to svn_cl__print_conflict_stats().

* subversion/svn/patch-cmd.c

(svn_cl__patch): Same.

* subversion/svn/switch-cmd.c

(svn_cl__switch): Same.

* subversion/svn/update-cmd.c

(svn_cl__update): Same.

  1. … 6 more files in changeset.
Remove the 'depth' parameter from svn_cl__resolve_postponed_conflicts(), as

it was mis-used and unnecessary (and undocumented).

The function resolves the conflicts on a pre-selected set of specific paths.

It was resolving to the specified depth within each such path, but the

callers were mistakenly passing the depth of the overall merge/update/switch


* subversion/svn/cl.h,


(svn_cl__resolve_postponed_conflicts): Remove the 'depth' parameter.

* subversion/svn/merge-cmd.c

(svn_cl__merge): Adjust caller.

* subversion/svn/switch-cmd.c

(svn_cl__switch): Adjust caller.

* subversion/svn/update-cmd.c

(svn_cl__update): Adjust caller.

  1. … 4 more files in changeset.
When a binary mime-type is set on a file that looks like a text file,

make the 'svn' client print a warning about potential future problems

with operations such as diff, merge, and blame.

This is only done during local propset for now, because the file needs

to be present on disk to detect its mime-type.

See for related discussion:

* subversion/svn/cl.h

(svn_cl__propset_print_binary_mime_type_warning): Declare.

* subversion/svn/propedit-cmd.c

(svn_cl__propedit): Warn when a binary svn:mime-type property value is

set on a local file that looks like text.

* subversion/svn/propset-cmd.c

(svn_cl__propset): Warn when a binary svn:mime-type property value is

set on a local file that looks like text.

* subversion/svn/util.c

(svn_cl__propset_print_binary_mime_type_warning): New helper function.

* subversion/tests/cmdline/

(blame_binary): Adjust text expectations.

* subversion/tests/cmdline/

(commit_one_new_binary_file): Adjust test expectations.

* subversion/tests/cmdline/

(diff_force, diff_mime_type_changes):

* subversion/tests/cmdline/

(binary_tree_conflict): Adjust test expectations.

* subversion/tests/cmdline/


merge_binary_file_with_keywords): Adjust test expectations.

* subversion/tests/cmdline/

(binary_mime_type_on_text_file_warning): New constant.

(inappropriate_props): Adjust test expectations.

* subversion/tests/cmdline/

(diff_binary): Adjust test expectations.

  1. … 10 more files in changeset.
Improve doc strings for some conflict resolution functions.

* subversion/svn/cl.h



svn_cl__resolve_postponed_conflicts): Better doc strings.

* subversion/svn/conflict-callbacks.c

(svn_cl__conflict_func_postpone): Remove doc string from here since it is

in the header file.

  1. … 1 more file in changeset.
* subversion/svn/cl.h

(svn_cl__accept_t): Remove obsolete comments.

To finally close issue #3009, and for similarity with 'svnlook diff', add a

--no-diff-added output filtering argument to 'svn diff'.

* subversion/include/svn_client.h


svn_client_diff_peg6): Update arguments.

* subversion/libsvn_client/deprecated.c


svn_client_diff_peg5): Update caller.

* subversion/libsvn_client/diff.c

(diff_cmd_baton): Add variable.

(diff_file_added): Filter diff if requested.


svn_client_diff_peg6): Set value in baton.

* subversion/svn/cl.h

(svn_cl__opt_state_t.diff): Add variable.

* subversion/svn/diff-cmd.c

(svn_cl__diff): Update caller.

* subversion/svn/log-cmd.c

(svn_cl__log): Update caller.

* subversion/svn/svn.c

(svn_cl__longopt_t): Add value.

(svn_cl__options): Add argument.

(svn_cl__cmd_table): Declare --no-diff-added for diff.

(sub_main): Parse argument.

  1. … 6 more files in changeset.
Update code comments in a number of files which refer to "main.c", where

the file has been renamed.

* subversion/svnrdump/load_editor.c:

(get_lock): Change comment to refer to "similar" function.

in subversion/svnsync/svnsync.c

Change comment to fix reference to "main.c"

* subversion/svnsync/svnsync.c:

(get_lock): Change comment to refer to "similar" function.

in subversion/svnsync/svnsync.c

* subversion/tests/svn_test_main.c:

(Opening comment): Fix file name after rename

* subversion/svndumpfilter/svndumpfilter.c:

(Opening comment): Fix file name after rename

* subversion/svn/cl.h:

(svn_cl__cmd_table[]): Fix file name in comment

(svn_cl__global_options[]): Fix file name in comment

(svn_cl__options[]): Fix file name in comment

* subversion/svn/svn.c:

(Opening comment): Fix file name after rename

* subversion/svnadmin/svnadmin.c:

(Opening comment): Fix file name after rename

* subversion/svnlook/svnlook.c:

(Opening comment): Fix file name after rename

* subversion/svnserve/svnserve.c:

(Opening comment): Fix file name after rename

Patch by: Gabriela Gibson <>

  1. … 8 more files in changeset.
Move some fairly useful utility functions from the command-line client

to libsvn_subr, exposing as private svn_cmdline__ APIs.

* subversion/include/private/svn_cmdline_private.h


svn_cmdline__edit_string_externally): Rename and move here ...

* subversion/svn/cl.h

(svn_cl__edit_file_externally, svn_cl__edit_string_externally):

... from here. Callers updated.

* subversion/libsvn_subr/cmdline.c

(find_editor_binary, svn_cmdline__edit_file_externally,

svn_cmdline__edit_string_externally): Rename and move here ...

* subversion/svn/util.c

(find_editor_binary, svn_cl__edit_file_externally,

svn_cl__edit_string_externally): ... from here. Callers updated.

* subversion/svn/conflict-callbacks.c,

* subversion/svn/file-merge.c,

* subversion/svn/propedit-cmd.c

Track function renames.

  1. … 6 more files in changeset.
Remove force_interactive from the global opt_state, and instead just use

a local variable to track whether --force-interactive was given.

This makes opt_state.non_interactive the authoritative global flag which

determines interactivity, matching an implicit assumption in the existing

command client code which looks at non_interactive only.

Suggested by: julianfoad

* subversion/svn/cl.h

(svn_cl__opt_state_t): Remove force_interactive.

* subversion/svn/svn.c

(sub_main): Use a local variable to track whether the --force-interactive

option was given.

  1. … 1 more file in changeset.
Add a new function to the cmdline library to determine whether standard

input is connected to a terminal device, and set the --non-interactive

option if standard input is not connected to a terminal device.

The idea is to make 'svn' non-interactive by default if run from scripts

which are launched in some unattended automated fashion. In such a situation

it is possible for scripts to hang if 'svn' decides to prompt for information

such as login credentials or conflict resolution options.

Also add a new --force-interactive option which enforces the old behaviour.

* subversion/include/svn_cmdline.h

(svn_cmdline__stdin_isatty): Declare.

* subversion/libsvn_subr/cmdline.c: Include io.h on Windows.

(svn_cmdline__stdin_isatty): New.

* subversion/svn/cl.h

(svn_cl__opt_state_t): Add force_interactive option.

* subversion/svn/svn.c

(svn_cl__longopt_t): Add opt_force_interactive.

(sub_main): Set the --non-interactive option based on whether stdin is a tty,

unless interactive mode has been forced with --force-interactive.

Enforce mutual exclusion of --non-interactive and --force-interactive.

* subversion/tests/cmdline/getopt_tests_data/svn_help_log_switch_stdout: Adjust.

* subversion/tests/cmdline/

(eof_in_interactive_conflict_resolver): Pass --force-interactive to ensure

the interactive conflict resolver will be run as expected.

  1. … 5 more files in changeset.
Add --show-inherited-props support to 'svnlook propget' and

'svnlook proplist' and '--verbose' support to 'svnlook propget'.

The output of these new options now mimics the output of 'svn pl' and

'svn pg' with the same options. The only change to *existing* 1.7 behavior

is for 'svnlook pl' and 'svnlook pl -v', which now mimics 'svn pl' and

'svn pl -v':


>svnlook pl autoprop_tests-30 /


>svnlook pl autoprop_tests-30 / -v

svn:auto-props : *.h=svn:eol-style=native


>svnlook pl autoprop_tests-30 /

Properties on '/':


>svnlook pl autoprop_tests-30 / -v

Properties on '/':



See and

* subversion/include/svn_repos.h

(svn_repos_fs_get_inherited_props): Add a new argument signaling retrieval

of only a particular property.

* subversion/libsvn_repos/fs-wrap.c

(svn_repos_fs_get_inherited_props): Implement new argument.

* subversion/libsvn_ra_local/ra_plugin.c


* subversion/mod_dav_svn/reports/inherited-props.c


* subversion/svnserve/serve.c


Update calls to svn_repos_fs_get_inherited_props() to account for new


* subversion/svn/cl.h



svn_cl__indent_string): Renamed and moved to svn_cmdline_private.h

* subversion/include/private/svn_cmdline_private.h



svn_cmdline__print_xml_prop_hash): New. Moved here from cl.h.

* subversion/svn/props.c


svn_cl__print_xml_prop_hash): Renamed and moved these implementations to


* subversion/svn/util.c


svn_cl__indent_string): Renamed and moved these implementations to


* subversion/libsvn_subr/cmdline.c


svn_cmdline__indent_string): New. Renamed and moved here from



svn_cmdline__print_xml_prop_hash): New. Renamed and moved here from


* subversion/svn/log-cmd.c


* subversion/svn/propget-cmd.c


* subversion/svn/proplist-cmd.c




Account for svn_cl__* --> svn_cmdline__* renamed functions.

* subversion/svnlook/svnlook.c

(svnlook__show_inherited_props): New enum for --show-inherited-props


(options_table): New help line for --show-inherited-props.

(cmd_table): Add '-v' and '--show-inherited-props' options to

'svnlook propget'. Add '--show-inherited-props' option to

'svnlook proplist'.

(svnlook_opt_state): Add member to track --show-inherited-props.


(do_pget): Add new arguments corresponding to the --verbose and

--show-inherited-props options.

(do_plist): Remove comment about returning SVN_ERR_PROPERTY_NOT_FOUND

if no properties are found, we haven't done that ever for proplist,

it appears to simply be a copy & paste typo from way back in r845574.

Add new argument corresponding to the --show-inherited-props option.

(subcommand_pget): Update call to do_plist() and do_pget().

(main): Handle --show-inherited-props. Raise an error if --revprop and

--show-inherited-props options are used together.

* subversion/svnserve/serve.c

(get_props): Update caller.

* subversion/tests/cmdline/

(output_command): Adjust test expectations to account for change in default

output of .svnlook pl'.

* tools/client-side/svn-bench/cl.h

(svn_cl__print_prop_hash): Remove declaration. No need to rename to

svn_cmdline__print_prop_hash, as it was no longer referenced in


  1. … 15 more files in changeset.
Further constrain when we require --force to set a property whose name

does not start with svn:

* subversion/svn/cl.h (svn_cl__check_svn_prop_name): Document exactly how

we match property names.

* subversion/svn/props.c: Get rid of all qsort_r cruft.

(svn_cl__check_svn_prop_name): Implement stricter matching rules.

* subversion/tests/cmdline/ (almost_known_prop_names): Add cases

that cover the stricter matching rules.

  1. … 2 more files in changeset.
Issue #4261 (require --force to set unknown svn: prop names)

* subversion/svn/cl.h (svn_cl__check_svn_prop_name): New prototype.

* subversion/svn/props.c: Include stdlib.h for qsort or qsort_r.

Include svn_string_private.h for svn_string__similarity.

(svn_cl__check_svn_prop_name): Implement.

(simprop_context_t, simprop_t, simprop_key_diff, simprop_compare):

New helpers for svn_cl__check_svn_prop_name.

  1. … 1 more file in changeset.
Merge the inheritable-props branch back to trunk.


  1. … 68 more files in changeset.
Change the way the command line client handles conflicted paths.

As of r1357313 the list of conflicted paths was stored in the notifier's

baton. Storing the list there would cause crashes when running with

the --quiet option because that option disables use of the notifier.

For details, see

Instead, use two separate conflict resolver callback functions, one

for postponing all conflicts and one for performing actual conflict

resolution, either interactive or based on the --accept option.

This approach was suggested by rhuijben.

While at it, hide implementation details of these functions, such as

the baton structure, completely within the conflict resolution code

in conflict-callbacks.c by introducing new svn_cl__ API functions.

* subversion/svn/cl.h

(svn_cl__opt_state_t): Remove conflict_func and conflict_baton. Now unused.

(svn_cl__conflict_baton_t): Renamed to ...

(svn_cl__interactive_conflict_baton_t): ... this. Now declared as an opaque


(svn_cl__conflict_baton_make): Rename to ...

(svn_cl__get_conflict_func_interactive_baton): ... this. Adjust parameter

list to simplify this interface from the caller's point of view.

(svn_cl__conflict_handler): Rename to ...

(svn_cl__conflict_func_interactive): ... this.


svn_cl__conflict_func_postpone): New.


svn_cl__notifier_get_conflicted_paths): Remove these declarations.

(svn_cl__resolve_conflicts): Rename to ...

(svn_cl__resolve_postponed_conflicts): ... this. Move declaration up in the

file to group it with related functions. This function now expects a baton

from svn_cl__conflict_func_postpone() as an argument, rather than a list

of conflicted paths, to hide the details of conflicted paths from the caller.

* subversion/svn/conflict-callbacks.c


svn_cl__get_conflict_func_interactive_baton): New baton and constructor.

(open_editor, launch_resolver, handle_text_conflict,

handle_prop_conflict): Track rename of interactive conflict baton.

(svn_cl__conflict_handler): Rename to ...

(svn_cl__conflict_func_interactive): ... this, and track baton renaming.



get_postponed_conflicted_paths): New helpers, partly based on notify.c.

(svn_cl__resolve_conflicts): Rename to ...

(svn_cl__resolve_postponed_conflicts): ... this, and expect a baton

argument which corresponds to a baton from svn_cl__conflict_func_postpone().

The list of conflicted paths is obtained from it, and the interactive

conflict resolution function is run on these paths via svn_client_resolve().


* subversion/svn/main.c

(sub_main): Adjust setup of interactive conflict resolution callback. Always

install svn_cl__conflict_func_postpone in the client context by default.

Subcommands may override this (currently only 'svn resolve' will do so).

Re-shuffle handling of options related to conflict resolution a little for

clarity (no behaviour change).

* subversion/svn/merge-cmd.c

(svn_cl__merge): Use svn_cl__resolve_postponed_conflicts() to resolve

any conflicts after the merge.

* subversion/svn/notify.c

(notify_baton): Remove conflicted_paths list.

(add_conflicted_path): Remove.

(notify): Don't call add_conflicted_path() anymore.

(svn_cl__get_notifier): Don't set up conflicted_paths anymore.


svn_cl__notifier_get_conflicted_paths): Remove, superseded by the

postponing conflict function.

* subversion/svn/resolve-cmd.c

(svn_cl__resolve): Cope with the fact that conflict_func was removed

from opt_state. Force use of the interactive resolver with this

subcommand so it can serve its purpose.

* subversion/svn/switch-cmd.c

(svn_cl__switch): Use svn_cl__resolve_postponed_conflicts() to resolve

any conflicts after the switch.

* subversion/svn/update-cmd.c

(svn_cl__update): Use svn_cl__resolve_postponed_conflicts() to resolve

any conflicts after the update.

  1. … 7 more files in changeset.
Remove the --isearch and --isearch-and options, and make the --search and

--search-and option case insensitive by default. This unclutters the log

search interface a little while generally still yielding useful results.

Suggested by: julianfoad

* subversion/svn/cl.h

(svn_cl__search_pattern_t): Remove, now unused. This was only used

to tie each pattern to a boolean that indicated whether case-insensitive

matching was requested.

* subversion/svn/log-cmd.c

(match_search_pattern): Remove case_insensitive_search parameter.

Expect a "const char *" pattern, not an svn_cl__search_pattern_t.

Always match patterns case-insensitively.

* subversion/svn/main.c

(svn_cl__longopt_t, svn_cl__cmd_table): Remove the opt_isearch and

opt_isearch_and options.

(svn_cl__options): Remove --isearch and --isearch-and.

(add_search_pattern_group, add_search_pattern_to_latest_group): Remove

case_insensitive parameter. Add patterns to the group as "const char *",

instead of as svn_cl__search_pattern_t.

(sub_main): Remove opt_isearch and opt_isearch_and handling, and track

removed function parameters.

* subversion/tests/cmdline/

(log_search): Verify that --search matches case-insensitively.

  1. … 3 more files in changeset.
Allow multiple --search options with 'svn log'. Log messages are shown

if they match any of the provided search patterns (i.e. logical OR).

This will be extended later with a new --search-and option to allow

for AND/OR combining of search terms (idea from philip).

* subversion/svn/cl.h

(svn_cl__search_pattern_t): New data type.

(svn_cl__opt_state_t): Replace search_pattern and case_insensitive_search

with an array of svn_cl__search_pattern_t objects.

* subversion/svn/log-cmd.c

(log_receiver_baton): As above, search_pattern and case_insensitive_search

become an array of search patterns.

(match_search_patterns): New helper to match multiple patterns.

(log_entry_receiver, log_entry_receiver_xml): Call the new helper.

(svn_cl__log): Track changes made to log_receiver_baton.

* subversion/svn/main.c

(svn_cl__cmd_table): Document the effect of multiple --search options in

the output of 'svn help log'.

(add_search_pattern): New helper to create an array of search patterns

from option arguments.

(sub_main): Use new helper for processing --search and --isearch options.

* subversion/tests/cmdline/getopt_tests_data/svn_help_log_switch_stdout: Adjust

to new output of 'svn help log'.

* subversion/tests/cmdline/

(log_search): Add a simple test case for multiple --search options.

  1. … 4 more files in changeset.