LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   diff output meaning (https://www.linuxquestions.org/questions/linux-software-2/diff-output-meaning-761311/)

sloganyart 10-12-2009 04:11 AM

diff output meaning
 
Hi,

I have been searching both in google and LQ but just couldn't get any, hope my question is never answered before :)

When I use
Quote:

diff fileA fileB
I got output like this:

Quote:

947,951c947,950
<
<
<
--
>
>
>

1039,1054d1037
<
<
1061a1045,1052
>
>
>
1155d1145
<
<
1294a1182,1183
>
>
Could anyone shed some light about the meaning of:
comma
a
c
c
in the output of diff ?

Thanks a million for the help, that's make a great help to me.

lutusp 10-12-2009 04:51 AM

Quote:

Originally Posted by sloganyart (Post 3716204)
Hi,

I have been searching both in google and LQ but just couldn't get any, hope my question is never answered before :)

When I use


I got output like this:



Could anyone shed some light about the meaning of:
comma
a
c
c
in the output of diff ?

Thanks a million for the help, that's make a great help to me.

Code:

$ man diff

sloganyart 10-12-2009 07:52 AM

I'm not sure the man diff you got is it same with mine, but as far I can tell, the man page didn't tell us the meaning of the format of the diff output. (I'm referring to Centos 5.3 here)

What I want to know is the meaning of comma, a, c, d in the output which sit among the digits. Thanks.

pixellany 10-12-2009 08:06 AM

Google is your friend: ... http://www.linuxselfhelp.com/gnu/dif...er/diff_3.html


I am surprised that the man pages don't give more info on output formats....

sloganyart 10-13-2009 01:32 AM

Thanks pixellany, your help is really appreciated :)

I guess my searching skill in google need to be sharpen a little bit more..


All times are GMT -5. The time now is 04:39 PM.