subversion-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1443226 - /subversion/trunk/subversion/svn/conflict-callbacks.c
Date Wed, 06 Feb 2013 21:33:37 GMT
Author: stsp
Date: Wed Feb  6 21:33:37 2013
New Revision: 1443226

URL: http://svn.apache.org/viewvc?rev=1443226&view=rev
Log:
Tweak the option descriptions shown by the 'help' option of the interactive
conflict prompt, for the case where there was a tree-conflict with a local
move during update/switch.

* subversion/svn/conflict-callbacks.c
  (tree_conflict_options_update_moved_away): New option menu for update-move
   conflicts, explaining the effect of the possible options more clearly than
   the standard tree-conflicts menu does.
  (handle_tree_conflict): Display the new update-move menu if appropriate.

Modified:
    subversion/trunk/subversion/svn/conflict-callbacks.c

Modified: subversion/trunk/subversion/svn/conflict-callbacks.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/conflict-callbacks.c?rev=1443226&r1=1443225&r2=1443226&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/conflict-callbacks.c (original)
+++ subversion/trunk/subversion/svn/conflict-callbacks.c Wed Feb  6 21:33:37 2013
@@ -390,6 +390,21 @@ static const resolver_option_t tree_conf
   { NULL }
 };
 
+static const resolver_option_t tree_conflict_options_update_moved_away[] =
+{
+  { "p",  "postpone",         N_("resolve the conflict later"),
+                              svn_wc_conflict_choose_postpone },
+  { "mc", "mine-conflict",    N_("apply the update to the move destination"),
+                              svn_wc_conflict_choose_mine_conflict },
+  { "tc", "theirs-conflict",  N_("break the move, change move destination into "
+                                 "a copy"),
+                              svn_wc_conflict_choose_theirs_conflict },
+  { "q",  "quit",             N_("postpone all remaining conflicts"),
+                              svn_cl__accept_postpone },
+  { "h",  "help",             N_("show this help (also '?')"), -1 },
+  { NULL }
+};
+
 /* Return a pointer to the option description in OPTIONS matching the
  * one- or two-character OPTION_CODE.  Return NULL if not found. */
 static const resolver_option_t *
@@ -823,11 +838,20 @@ handle_tree_conflict(svn_wc_conflict_res
   while (1)
     {
       const resolver_option_t *opt;
+      const resolver_option_t *tc_opts;
 
       svn_pool_clear(iterpool);
 
-      SVN_ERR(prompt_user(&opt, tree_conflict_options, NULL, b->pb,
-                          iterpool));
+      if ((desc->operation == svn_wc_operation_update ||
+           desc->operation == svn_wc_operation_switch) &&
+          desc->reason == svn_wc_conflict_reason_moved_away)
+        {
+          tc_opts = tree_conflict_options_update_moved_away;
+        }
+      else
+        tc_opts = tree_conflict_options;
+
+      SVN_ERR(prompt_user(&opt, tc_opts, NULL, b->pb, iterpool));
       if (! opt)
         continue;
 



Mime
View raw message