How to compare files using diff - LinuxConfig.org

The diff utility is, in the vast majority of cases, installed by default in every Linux distribution out there. The program is used to calculate and display the differences between the contents of two files. It is mainly used when working with source code two compare the same versions of two files and highlight the differences between them. In this article we will learn the various modes in which diff can work and how to create a diff file which can later be applied as a patch with the patch utility.


This is a companion discussion topic for the original entry at https://linuxconfig.org/how-to-compare-files-using-diff