Checkout Tools
  • last updated 1 hour ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Let the WC mods editor and WC replay editor APIs take explicit notification

callbacks.

* subversion/include/private/svn_client_private.h

(svn_client__wc_replay,

svn_client__wc_copy_mods): Take a notification callback.

* subversion/libsvn_client/commit.c

(svn_client__wc_replay): Take a notification callback.

* subversion/libsvn_client/wc_editor.c

(svn_client__wc_copy_mods): Take a notification callback.

* subversion/svn/shelf-cmd.c

(svn_cl__wc_copy_mods): Adjust caller.

  1. … 3 more files in changeset.
Implement an experimental 'x-wc-copy-mods' command.

This can be used to comprehensively test the WC editor (issue #4786).

* subversion/include/private/svn_client_private.h,

subversion/libsvn_client/wc_editor.c

(svn_client__wc_copy_mods): New.

* subversion/svn/svn.c

(svn_cl__cmd_table): Add 'x-wc-copy-mods' command.

* subversion/svn/cl.h

(svn_opt_subcommand_t): Declare 'svn_cl__wc_copy_mods'.

* subversion/svn/shelf-cmd.c

(svn_cl__wc_copy_mods): New.

  1. … 4 more files in changeset.
Move all experimental APIs to the private namespace.

Part of issue SVN-4775 "Add x- prefix to experimental APIs".

* subversion/include/svn_client.h

(svn_client__layout_func_t): Renamed from 'svn_client_layout_func_t'.

(svn_client__layout_list): Renamed from 'svn_client_layout_list'.

(svn_client_shelf_*): Rename to 'svn_client__shelf_*'.

* subversion/include/private/svn_client_private.h

(svn_client__shelf_diff): Track the renames.

* subversion/libsvn_client/diff.c

(diff_shelf): Track the renames.

* subversion/libsvn_client/layout.c

(client_layout_baton_t,

svn_client__layout_list): Track the renames.

* subversion/libsvn_client/shelf.c

Track the renames.

* subversion/libsvn_client/status.c

(shelf_status): Track the renames.

* subversion/svn/info-cmd.c

Track the renames.

* subversion/svn/shelf-cmd.c

Track the renames.

  1. … 7 more files in changeset.
Fix 'svn shelf-diff' breakage in r1835446.

* subversion/svn/shelf-cmd.c

(shelf_diff,

svn_cl__shelf_diff): Pass 'depth' and 'ignore_ancestry' arguments through.

Shelving: implement shelf diff summary mode.

"svn shelf-diff --summarize"

* subversion/include/private/svn_client_private.h,

subversion/libsvn_client/client.h,

subversion/libsvn_client/diff_summarize.c

(svn_client__get_diff_summarize_callbacks): Move from a private to a

semi-public header file. Remove 'const' from the output parameter.

* subversion/libsvn_client/diff.c

(svn_client_diff_summarize2,

svn_client_diff_summarize_peg2): Tweak to match that 'const' change.

* subversion/svn/cl.h,

subversion/svn/diff-cmd.c

(svn_cl__get_diff_summarize): Newly exposed API.

(svn_cl__diff): Use it.

* subversion/svn/shelf-cmd.c

(shelf_diff): Implement summary mode.

* subversion/svn/svn.c

(svn_cl__cmd_table): Add '--summarize' option to shelf-diff.

* subversion/tests/cmdline/shelf_tests.py

(shelf_diff_simple): Extend to test summary mode.

* tools/client-side/bash_completion

(_svn): Add '--summarize' option to shelf-diff.

  1. … 9 more files in changeset.
Shelving: Implement 'svn shelf-diff', issue SVN-4745.

This is a first pass. It drives only the file methods in the diff processor

API, not the open- and close-directory methods, and not reporting changes on

directories.

* subversion/include/svn_client.h

(svn_client_shelf_export_patch): Deprecate.

* subversion/include/private/svn_client_private.h

(svn_client__get_diff_writer_unidiff): New.

(svn_client__shelf_diff): New.

* subversion/libsvn_client/diff.c

(svn_client__get_diff_writer_unidiff): New.

* subversion/libsvn_client/shelf.c

(file_changed, file_deleted, file_added): New.

(diff_baton_t, diff_visitor): Drive a diff-processor from shelved changes.

(svn_client__shelf_diff): New.

(svn_client_shelf_export_patch): Delete the body; it is deprecated and did

nothing before.

* subversion/svn/shelf-cmd.c

(shelf_diff): First obtain a diff writer. Then call the shelf-diff API,

driving that writer.

* subversion/tests/cmdline/shelf_tests.py

(shelf_diff_simple): New test.

(test_list): Run it.

  1. … 5 more files in changeset.
Fix use of implicit path when calling shelf-{list,log,drop} from a wc-subdir

* subversion/svn/shelf-cmd.c:

(svn_cl__shelf_list, svn_cl__shelf_drop, svn_cl__shelf_log): Convert targets

to absolute paths

* subversion/tests/cmdline/shelf_tests.py:

(shelve_unshelve_verify): Add an assertion for "svn shelves"

  1. … 1 more file in changeset.
Shelving: tweak top-of-file comments.
  1. … 1 more file in changeset.
Allow "svn x-shelf-log" from outside the working copy.

* subversion/svn/shelf-cmd.c

(svn_cl__shelf_log): Accept path arguments, supply default '.' path.

* subversion/svn/svn.c

(svn_cl__cmd_table): Update help text.

  1. … 1 more file in changeset.
Shelving: Handle no-such-version scenarios better.

* subversion/libsvn_client/shelf.c

(svn_client_shelf_set_current_version): Don't try to open version 0.

(svn_client_shelf_version_open): Throw an error on trying to open

a non-existent version, as is already documented.

* subversion/svn/shelf-cmd.c

(get_newest_version_existing): New.

(shelf_restore,

shelf_diff): Use it, thus throwing a suitable error on a non-existent version.

(shelves_list): Write "no versions" explicitly when it is so.

(shelf_list_by_paths): Don't try to read from shelves with no versions.

  1. … 1 more file in changeset.
Allow "svn x-shelf-drop" from outside the working copy.

* subversion/svn/shelf-cmd.c

(svn_cl__shelf_drop): Accept path arguments, supply default '.' path.

* subversion/svn/svn.c

(svn_cl__cmd_table): Update help text.

  1. … 1 more file in changeset.
* subversion/svn/shelf-cmd.c

(svn_cl__shelf_list): Rename subpool and use it properly.

Allow "svn x-shelf-list" from outside the working copy.

* subversion/svn/shelf-cmd.c

(svn_cl__shelf_list): Accept path arguments, supply default '.' path.

* subversion/svn/svn.c

(svn_cl__cmd_table): Update help text.

  1. … 1 more file in changeset.
Shelving: better reporting of shelved and not-shelved changes.

* subversion/include/svn_client.h,

subversion/libsvn_client/shelf.c

(svn_client_shelf_save_new_version3): New.

(svn_client_shelf_save_new_version2): Deprecate.

* subversion/svn/shelf-cmd.c

Use callbacks to report shelved and not-shelved paths.

  1. … 2 more files in changeset.
Shelving: Make the 'conflict on unshelving' error more informative.

* subversion/svn/shelf-cmd.c

(status_to_char): New.

(test_apply): Report the WC status code of the conflicting path.

(shelf_restore): Tweak the conflict error message.

Shelving: Use whole-file storage and 3-way merge.

Use whole-file storage completely, instead of patch storage, and use

3-way merge to apply changes to a working file (and dir props).

Don't discriminate 'binary' files at storage time. When unshelving

(applying) a change, treat 'binary' files by the choose-one-or-the-other

method; raise a conflict if the working file differs from the stored

base.

In other words, this is closer to how a normal merge works.

TODO:

- The svn_client_shelf_export_patch() API is disabled for now.

- Handling of conflicts is weak.

* subversion/include/svn_client.h

(svn_client_shelf_test_apply_file): Avoid using the term 'patch' in the

doc string.

* subversion/libsvn_client/shelf.c

Implement storage of base and working text and props. Remove storage in

patch files.

* subversion/svn/shelf-cmd.c

Remove detection of 'reject' notifications from patching. Avoid using the

term 'patch' in doc strings.

* subversion/tests/cmdline/shelf_tests.py

(shelve_empty_deletes): Remove XFail, as now passes.

  1. … 3 more files in changeset.
* subversion/svn/shelf-cmd.c

(check_no_modified_paths): Remove unused function.

Shelving: refuse to unshelve if there are conflicts.

* subversion/include/svn_client.h,

subversion/libsvn_client/shelf.c

(svn_client_shelf_apply): Document better.

(patch_filter_baton_t, patch_filter,

patch_notify_baton_t, patch_notify,

svn_client_shelf_test_apply_file): New.

* subversion/svn/shelf-cmd.c

(test_apply): New.

(shelf_restore): Error if any path would have a conflict, unless forced.

* subversion/tests/cmdline/shelf_tests.py

(state_from_status): Move to top of file...

(shelve_unshelve_verify): ... and use to simplify here.

(unshelve_refuses_if_conflicts): New.

(test_list): Run it.

  1. … 3 more files in changeset.
Shelving: unshelve --force will bypass the check for local modifications.

* subversion/svn/shelf-cmd.c

(shelf_restore): Don't check for mods if so requested.

(svn_cl__shelf_unshelve): Pass through the option.

* subversion/svn/svn.c

(svn_cl__cmd_table): Add and document 'unshelve --force' option.

  1. … 1 more file in changeset.
Shelving: fix problems when a shelf has zero versions.

* subversion/libsvn_client/shelf.c

(shelf_read_revprops): Document better.

(shelf_read_current): Distinguish no versions from non-existent.

(svn_client_shelf_open_existing): Allow opening a shelf with no versions.

(svn_client_shelf_open_or_create): Handle creating a shelf with no

versions.

* subversion/svn/shelf-cmd.c

(shelves_list): Display the shelf name even if it has no versions.

  1. … 1 more file in changeset.
* subversion/svn/shelf-cmd.c

(stats): Restore a newline dropped accidentally in r1826614.

* subversion/svn/shelf-cmd.c

(svn_cl__shelf_log): Remove unused variable.

Shelving: drop the 'diffstat' from 'list' and 'log' output because it's a

non-universal external dependency and wasn't really important.

We can add a proper 'diffstat' mode to Subversion in future if we want to,

independent of shelving.

Shelving: make UI strings better for localization.

Suggested by: mattiase

Shelving: reduce the API's reliance on integer version numbers.

* subversion/include/svn_client.h,

subversion/libsvn_client/shelf.c

(svn_client_shelf_t): Deprecate 'max_version'.

(svn_client_shelf_version_t): Add the version number as a private member.

(svn_client_shelf_save_new_version2): New.

(svn_client_shelf_save_new_version): Deprecate.

(svn_client_shelf_delete_newer_versions): New.

(svn_client_shelf_set_current_version): Deprecate.

(svn_client_shelf_version_open): Tweak docs and parameter name.

(svn_client_shelf_get_newest_version): New.

(svn_client_shelf_get_all_versions): New.

* subversion/svn/shelf-cmd.c

Update accordingly.

  1. … 2 more files in changeset.
Shelving: new 'shelf-list-by-paths' command.

* subversion/svn/cl.h

(svn_cl__shelf_list_by_paths): New.

* subversion/svn/shelf-cmd.c

(targets_relative_to_wcs,

targets_relative_to_a_wc,

shelf_list_by_paths,

svn_cl__shelf_list_by_paths): New.

* subversion/svn/svn.c

(svn_cl__cmd_table): Describe the new command.

* tools/client-side/bash_completion

(_svn): Add the new command.

  1. … 3 more files in changeset.
Shelving: add 'svn unshelve --drop' option.

* subversion/svn/cl.h

(svn_cl__opt_state_t): Add new 'drop' flag.

* subversion/svn/shelf-cmd.c

(svn_cl__shelf_unshelve): Drop after shelving, if successful.

* subversion/svn/svn.c

(svn_cl__longopt_t,

svn_cl__options,

svn_cl__cmd_table,

sub_main): Add new 'drop' option.

* tools/client-side/bash_completion

(_svn): Add new 'drop' option.

  1. … 3 more files in changeset.
Shelving: Detect when there is a conflict in unshelving.

* subversion/svn/shelf-cmd.c

(patch_notify_baton_t, patch_notify): New.

(shelf_restore): Intercept patch notifications and error if there is a conflict.

Shelving: Follow-up to r1825353: fix crashes and beautify the API.

* subversion/svn/shelf-cmd.c

(shelve): Don't assume the revprops table is non-null.

* subversion/include/svn_client.h,

subversion/libsvn_client/shelf.c

(svn_client_shelf_set_log_message): Make the input message 'const'.

  1. … 2 more files in changeset.
Shelving: Make a simpler log message set/get API.

* subversion/include/svn_client.h,

subversion/libsvn_client/shelf.c

(svn_client_shelf_revprop_set_all): New

(svn_client_shelf_set_log_message): Simply set a log message; no callback

and no other revprops.

(svn_client_shelf_get_log_message): Document more fully.

* subversion/svn/shelf-cmd.c

(shelve): Do the client-specific callback dance here instead.

  1. … 2 more files in changeset.