You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2011/08/18 22:16:14 UTC

svn commit: r1159400 - /subversion/trunk/subversion/svn/main.c

Author: stsp
Date: Thu Aug 18 20:16:14 2011
New Revision: 1159400

URL: http://svn.apache.org/viewvc?rev=1159400&view=rev
Log:
* subversion/svn/main.c
  (svn_cl__cmd_table): In the 'svn patch' help text, mention a neat trick
   that allows resolving patch conflicts interactively in some situations.

Inspired by: hwright
(who mentioned this trick to me at some point)

Modified:
    subversion/trunk/subversion/svn/main.c

Modified: subversion/trunk/subversion/svn/main.c
URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/svn/main.c?rev=1159400&r1=1159399&r2=1159400&view=diff
==============================================================================
--- subversion/trunk/subversion/svn/main.c (original)
+++ subversion/trunk/subversion/svn/main.c Thu Aug 18 20:16:14 2011
@@ -1006,6 +1006,13 @@ const svn_opt_subcommand_desc2_t svn_cl_
      "  for deletion. If the patch creates a new file, that file is scheduled\n"
      "  for addition. Use 'svn revert' to undo deletions and additions you\n"
      "  do not agree with.\n"
+     "\n"
+     "  Hint: If the patch file was created with Subversion, it will contain\n"
+     "        the number of a revision N the patch will cleanly apply to\n"
+     "        (look for lines like \"--- foo/bar.txt        (revision N)\").\n"
+     "        To avoid rejects, first update to the revision N using \n"
+     "        'svn update -r N', apply the patch, and then update back to the\n"
+     "        HEAD revision. This way, conflicts can be resolved interactively.\n"
      ),
     {'q', opt_dry_run, opt_strip, opt_reverse_diff,
      opt_ignore_whitespace} },