www.delorie.com/gnu/docs/diffutils/diff_20.html   search  
Buy GNU books!

Comparing and Merging Files

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

2.3.2 Unified Format

The unified output format is a variation on the context format that is more compact because it omits redundant context lines. To select this output format, use the `-U lines', `--unified[=lines]', or `-u' option. The argument lines is the number of lines of context to show. When it is not given, it defaults to three.

At present, only GNU diff can produce this format and only GNU patch can automatically apply diffs in this format. For proper operation, patch typically needs at least three lines of context. Detailed Description of Unified Format  A detailed description of unified format. An Example of Unified Format  Sample output in unified format.

  webmaster   donations   bookstore     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003