![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| diff command | ariec | AIX | 3 | 06-05-2008 03:16 AM |
| need help in diff command : | ali560045 | Shell Programming and Scripting | 5 | 05-26-2008 09:22 AM |
| diff command | Vichu | Shell Programming and Scripting | 1 | 04-28-2008 07:06 AM |
| Need help with Scripting diff command | tlfletcher05 | Shell Programming and Scripting | 2 | 01-26-2008 02:19 AM |
| Diff command problem | gvsreddy_539 | Shell Programming and Scripting | 4 | 09-30-2007 08:36 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread |
Rating:
|
Display Modes |
|
||||
|
If dir1 is a directory
containing a directory named x, and dir2 is a directory containing a directory named x, dir1/x and dir2/x both contain files named date.out, and dir2/x contains a file named y, the command: example% diff -r dir1 dir2 could produce output similar to: Common subdirectories: dir1/x and dir2/x Only in dir2/x: y diff -r dir1/x/date.out dir2/x/date.out 1c1 Dont know if this helps more info in the man diff |
|
||||
|
Personally for more complicated diffs I prefer using a GUI program like kdiff3 with color-coding of different changed chunks, and you can use such kind of tools to merge conflicts very easily (and interactively).
P.S. Just for your information, I asked a related question on related diff command-line tools a couple of months earlier (though I eventually settled with GUI which I found from some obscure sources, and that seems to fit my needs really well): Interactive patching? |
|
||||
|
comparing two files
Hello All,
I thank you for your help but still i didn't succeed in comparing two files and recieving a new file which contains just the diffrences between the two. I need it badly with my everyday work. thanks,Irit |
|
||||
|
First produce a diff of two files, say file1 is the old copy, file2 is the newer copy.
diff file1 file2 > delta.diff Then you can apply the diff to file1 by using the patch command: patch -p0 < delta.diff file1 |
| Sponsored Links | ||
|
|
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|