hg extdiff#

use external program to diff repository (or selected files)#

hg extdiff [OPT]... [FILE]...

This command is provided by the extdiff extension.

Show differences between revisions for the specified files, using an external program. The default program used is diff, with default options "-Npru".

To select a different program, use the -p/--program option. The program will be passed the names of two directories to compare, unless the --per-file option is specified (see below). To pass additional options to the program, use -o/--option. These will be passed before the names of the directories or files to compare.

The --from, --to, and --change options work the same way they do for `hg diff`.

The --per-file option runs the external program repeatedly on each file to diff, instead of once on two directories. By default, this happens one by one, where the next file diff is open in the external program only once the previous external program (for the previous file diff) has exited. If the external program has a graphical interface, it can open all the file diffs at once instead of one by one. See `hg help -e extdiff` for information about how to tell Mercurial that a given program has a graphical interface.

The --confirm option will prompt the user before each invocation of the external program. It is ignored if --per-file isn't specified.

Options

-p

--program CMD

comparison program to run

-o

--option OPT [+]

pass option to comparison program

--from REV1

revision to diff from

--to REV2

revision to diff to

-c

--change REV

change made by revision

--per-file

compare each file instead of revision snapshots

--confirm

prompt user before each external program invocation

--patch

compare patches for two revisions

-I

--include PATTERN [+]

include names matching the given patterns

-X

--exclude PATTERN [+]

exclude names matching the given patterns

-S

--subrepos

recurse into subrepositories

--mq

operate on patch repository

Options marked [+] can be repeated.