Shell / Commands

diff

English

Overview

A command that shows the difference between two files.

Details

A command that compares the contents of two files or directories and outputs the difference, also used to generate a patch file. The -u option switches to the unified format, which shows surrounding context lines -- the same format underlying the diffs shown by version-control tools like Git.

More Linux terms