Mercurial > hg
changeset 7307:56380212d630
help: commands supporting --git point to the gitdiffs topic (issue1352)
author | Dirkjan Ochtman <dirkjan@ochtman.nl> |
---|---|
date | Mon, 03 Nov 2008 16:31:47 +0100 |
parents | 8e46e59aaf4c |
children | b6f5490effbf |
files | hgext/mq.py mercurial/commands.py tests/test-help.out |
diffstat | 3 files changed, 16 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- 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