help: commands supporting --git point to the gitdiffs topic (
issue1352)
--- a/hgext/mq.py Mon Nov 03 16:30:21 2008 +0100
+++ b/hgext/mq.py Mon Nov 03 16:31:47 2008 +0100
@@ -1600,7 +1600,8 @@
An existing changeset may be placed under mq control with --rev
(e.g. qimport --rev tip -n patch will place tip under mq control).
With --git, patches imported with --rev will use the git diff
- format.
+ format. See the gitdiffs help topic for information on why this is
+ important for preserving rename/copy information and permission changes.
"""
q = repo.mq
q.qimport(repo, filename, patchname=opts['name'],
@@ -1765,6 +1766,10 @@
-e, -m or -l set the patch header as well as the commit message. If none
is specified, the header is empty and the commit message is '[mq]: PATCH'.
+
+ Use the --git option to keep the patch in the git extended diff format.
+ Read the gitdiffs help topic for more information on why this is
+ important for preserving permission changes and copy/rename information.
"""
msg = cmdutil.logmessage(opts)
def getmsg(): return ui.edit(msg, ui.username())
@@ -1791,6 +1796,7 @@
hg add/remove/copy/rename work as usual, though you might want to use
git-style patches (--git or [diff] git=1) to track copies and renames.
+ See the gitdiffs help topic for more information on the git diff format.
"""
q = repo.mq
message = cmdutil.logmessage(opts)
--- a/mercurial/commands.py Mon Nov 03 16:30:21 2008 +0100
+++ b/mercurial/commands.py Mon Nov 03 16:31:47 2008 +0100
@@ -1003,6 +1003,9 @@
Without the -a option, diff will avoid generating diffs of files
it detects as binary. With -a, diff will generate a diff anyway,
probably with undesirable results.
+
+ Use the --git option to generate diffs in the git extended diff
+ format. Read the gitdiffs help topic for more information.
"""
node1, node2 = cmdutil.revpair(repo, opts.get('rev'))
@@ -1036,6 +1039,9 @@
it detects as binary. With -a, export will generate a diff anyway,
probably with undesirable results.
+ Use the --git option to generate diffs in the git extended diff
+ format. Read the gitdiffs help topic for more information.
+
With the --switch-parent option, the diff will be against the second
parent. It can be useful to review a merge.
"""
--- a/tests/test-help.out Mon Nov 03 16:30:21 2008 +0100
+++ b/tests/test-help.out Mon Nov 03 16:31:47 2008 +0100
@@ -215,6 +215,9 @@
it detects as binary. With -a, diff will generate a diff anyway,
probably with undesirable results.
+ Use the --git option to generate diffs in the git extended diff
+ format. Read the gitdiffs help topic for more information.
+
options:
-r --rev revision