[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[PATCH] Add option to resolve conflicts by selecting a specific file (Issue 2784)

From: Jeremy Whitlock <jcscoobyrs_at_gmail.com>
Date: 2007-06-01 04:54:32 CEST

Hi All,
    Attached is the patch used to resolve issue 2784. Here is a synopsis:

This patch adds the "--accept" or "-a" flag support to the Subversion
command line. Right now, only resolved subcommand is using it. This
new flag will also be used by the following subcommands:


I will be creating separate issues for each implementation of the
"--accept" flag for each subcommand and patches will be created for
each. Working on this also will mean revving the bindings to handle
this new functionality. Just like with making the other subcommands
support this flag, each binding will be working on as separate issues.
 All related issues will be created shortly after this email. As for
the log message for this patch, it will be at the bottom of this
message. Thanks to all that have helped during this patch.

Take care,


Add option to resolve conflicts by selecting a specific file by adding
support to the svn executable to handle the "--accept" flag. The
"resovled" subcommand is the only subcommand using this new flag as
part of this patch. (Issue 2784)

* subversion/include/svn_client.h
  (svn_client_resolved): Revved to svn_client_resolved2() to handle
the svn_accept_t enum.

* subversion/include/svn_types.h
  (svn_accept_t): Created an enum to handle the different accept options.
  (svn_accept_to_word): Function prototype for getting the string
representation of the accept options.
  (svn_accept_from_word): Function prototype to return the proper
svn_accept_t based on the accept word.

* subversion/include/svn_wc.h
  (svn_wc_walk_entries): Revved to svn_wc_walk_entries4 to handle the
svn_accept_t enum.
  (svn_wc_resolved_conflict): Revved to svn_wc_resolved_conflict3 to
handle the svn_accept_t enum.

* subversion/libsvn_client/resolved.c
  (svn_client_resolved): Implementation of svn_client_resolved2()
which now handles the svn_accept_t as an argument.

* subversion/libsvn_subr/kitchensink.c
  (svn_accept_to_word): Implementation of svn_accept_to_word() which
will take an svn_accept_t enum and return a string representation of
that enum.
  (svn_accept_from_word): Implementation of svn_accept_from_word()
which will return an svn_accept_t based on the passed accept string.

* subversion/libsvn_wc/adm_ops.c
  (resolve_conflict_on_entry): Updated this function to handle an
svn_accept_t argument. This is also where the real work of handling
the accept flag happens.
  (resolve_callback_baton): Updated the structure to have a
placeholder for the svn_accept_t argument so that
resolve_found_entry_callback() can pass the necessary information to
  (svn_wc_resolved_conflict): Implementation of
svn_wc_resolved_conflict3() which now handles the svn_accept_t as an

* subversion/svn/cl.h
  (svn_cl__opt_state_t): Updated to have a place holder for the accept
flag passed to the svn executable.

* subversion/svn/main.c
  (svn_cl__options): Updated to have all necessary information for the
svn executable to provide help for, and handle, the accept flag in
both long and short format.
  (svn_cl__cmd_table): Updated to have the resolved subcommand handle
the passing of the accept flag.
  (svn_cl__limit_opt): Added case statement to handle parsing the
accept flag and erroring when an invalid argument was passed. If a
valid argument is passed, it is then turned into the svn_accept_t enum
based on the svn_accept_from_word() function in

* subversion/svn/resolved-cmd.c
  (svn_cl__resolved): Updated to call the revved svn_client_resolved()
which is now at svn_client_resolved2().

* subversion/tests/cmdline/basic_test.py
  (automatic_conflict_resolution): Created a new test to test the
handling of the new accept flag for the resolved subcommand.
  (test_list): Added the automatic_conflict_resolution test to the test list.

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Received on Fri Jun 1 04:54:47 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.