[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: using diff command



Once upon a time Curtis Vaughan said...
> 
> Basically, the issue is this, I have 2 files: File1 File2
> 
> Both are text files. File1 was File2 a day ago. Since then File2 has had 
> additional information tagged on to it (it's a log file). All I want to 
> see is what information has been added since yesterday.  So, I would 
> think that "diff File2 File1" should provide me with that information. 
> But all I ever get is a message that the files differ.  I have tried 
> with various arguments, but no luck.

Does the message you get actually say: "*Binary* files File2 and File1
differ"? [emphasis mine].

If so, diff is seeing some non-ascii characters in the file and treating
them as binary.

Try:
$ diff -a File1 File2

-a says to treat all files as text.



Reply to: