Find Difference between 2 files in Linux

root@server2 [~/study]# cat file1
1
2
3
4
root@server2 [~/study]# cat file2
1
2
3
4
5
6
7
8

root@server2 [~/study]# diff file1 file2
4a5,9
> 5
> 6
> 7
> 8
>
root@server2 [~/study]#

here

4a5,9
means append 5 to 9 from position 4 and displayed rest part of file2 next to this result

abhilash

abhilash, is a programmer by profession and a technology addict with a passion towards browsing , shopping and imaging . My views may be biased on reviews. all images and videos are copyrighted to respective owners.

Add comment

Your Header Sidebar area is currently empty. Hurry up and add some widgets.