IMEDIFF(1) | imediff User Manual | IMEDIFF(1) |
imediff - An interactive fullscreen merge tool for 2 or 3 files
imediff [-a] [-b] [-d] [-f] [-h] [-m] [-n] [-t] [-o file_out] {file_older} {file_newer}
imediff [-a] [-b] [-c] [-d] [-f] [-g] [-h] [-m] [-n] [-t] [-o file_out] {file_yours} {file_base} {file_theirs}
Merge two (slightly different) files with an optional common base file interactively with a user friendly fullscreen interface in the full screen text terminal mode.
imediff shows the differences of given two files (in color if the terminal supports them), lets you scroll the file and toggle changes between older and newer version for each chunk of difference. You can also select line diff and character wdiff mode for display. If you wish to make manual changes, you can edit each chunk with editor. The result of merge operation is saved in file_out.
Additionally, you can customize your choice of editor via $EDITOR or ~/.imediff. The default editor is /usr/bin/editor.
Removed lines are shown in reversed '???' as a placeholder, so you see that and you can select them. While it takes one line on display, it is naturally not saved into the output file.
To see the key binding, hit h in the main imediff screen.
To see the tutorial, hit H in the main imediff screen or simply start the imediff command without arguments.
The program exits with status 0 if the changes were saved, 1 if the merging was aborted and 2 if the parameters were invalid.
-o file_output, --output=file_output
-m, --mode
--mono
--sloppy
-n
-a
-b
-c
-d
Start with diff by line between version A and version C while using version B as base version for 3 files.
-f
Start with wdiff by character between version A and version C while using version B as base version for 3 files.
-g
-h, --help
-t, --template
-V, --version
The following keyboard commands are available in the editor as default.
x
Save and exit unconditionally. (when --sloppy specified)
q, ctrl+c
home, t, end, z
h
shift+h
s, ?
down, j, up, k
left, right
page up, page down
enter
n, space
N, tab
p, backspace
P, back-tab
a
b
c
d
e
f
g
If the editor result buffer has content, mode is set to "e".
If a chunk is resolved cleanly, mode is set to "a", "c", or "g". This overrides previous manual settings such as "a", "b", or "c".
If a chunk isn't resolved cleanly, mode is left as mode "g" or "f".
shift+a
shift+b
shift+c
shift+d
shift+e
shift+f
shift+g
m
shift+m
The key choices of the above keyboard commands can be configured in ~/.imediff which is created at the first execution of this command. The left side is the keys described in this manpage. The right side is your configuration choices. The current settings can be confirmed by the 'h' key dialog.
sdiff (1), diff (1), merge (1), diff3 (1).
This manual page as well as the program itself was written by Jarno Elonen <elonen@iki.fi> and Osamu Aoki <osamu@debian.org>. Unlike the program itself, which is licensed under the GNU General Public License (GPL) version 2 (or any later version, at your option), this document has been placed into the Public Domain.
Jarno Elonen <elonen@iki.fi>
Osamu Aoki <osamu@debian.org>
Copyright © 2003-2006, 2018 Jarno Elonen <elonen@iki.fi>, Osamu Aoki <osamu@debian.org>
2018-12-11 | imediff |