Comparing files in Linux
We can use below commands to compare files in Linux.
- diff – Compare files line by line
- comm – Compare 2 sorted files line by line
- cmp – Compare 2 files byte by byte
“diff” command shows the difference between 2 files.
$ diff <file1Name> <file2Name>