Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 12-11-2003, 01:21 PM   #1
LQ Newbie
Registered: Dec 2003
Posts: 1

Rep: Reputation: 0
DIFF (or other file comparison)

Anyone know of a better file comparison utility other than DIFF? Or perhaps, let me know which flag for DIFF will compare two files and output ONLY the difference?

My scenario is I'm grepping var/log/messages for a string "global" and writing it to a file global.all

I then rename the file to global.old

Later, I grep var/log/messages again for "global" and write it to global.all

I now want to DIFF global.old and global.all and write the difference to

The problem is, that DIFF puts extra characters in its output, namely < and 07,d193

I only want the EXACT differences to be in the new file.

Any suggestions?
Old 12-11-2003, 02:13 PM   #2
Registered: Apr 2002
Location: in a fallen world
Distribution: slackware by choice, others too :} ... android.
Posts: 23,067
Blog Entries: 11

Rep: Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914Reputation: 914
Have a closer look at diff :}

man diff

Or use emacs ;)



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
What is *.diff file? carboncopy Slackware 1 05-19-2004 10:26 AM
how can i patch a file from source and diff? gunslinger77 Linux - General 1 04-21-2004 08:23 PM
File Modification Date Comparison MadTurki Programming 7 03-08-2004 04:02 PM
I have a patch (diff file). What now? Gurduloo Linux - Newbie 2 05-27-2003 02:20 PM
Good File Comparison Utility Witch-King Linux - Software 4 01-01-2003 10:13 PM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:28 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration