Linux 差分输出

Linux 差分输出,linux,diff,Linux,Diff,我有两个文件如下: file1.txt 0000075d-7f2c-4896-83b4-5738d23bc4ba 000066c6-1184-47fc-acf6-916cb640c3f4 0000913e-adf2-41be-b377-749bd656cbf5 0000cb55-9b2c-42ea-af3e-87d2c7713c13 00012ac0-a893-41c7-a806-27728a1127e2 00013bea-4be2-4270-8efe-c00cd57b525d 00014c1d

我有两个文件如下: file1.txt

0000075d-7f2c-4896-83b4-5738d23bc4ba
000066c6-1184-47fc-acf6-916cb640c3f4
0000913e-adf2-41be-b377-749bd656cbf5
0000cb55-9b2c-42ea-af3e-87d2c7713c13
00012ac0-a893-41c7-a806-27728a1127e2
00013bea-4be2-4270-8efe-c00cd57b525d
00014c1d-6a5d-4c5e-aff0-a44cf49c54d5
0001d18b-c5c8-41c4-bcb0-e3c8074cb39e
00022848-b122-4c6a-b810-51737db09a5b
00022b1e-0148-4dad-bb82-a9be457ed2e7
file2.txt

0000075d-7f2c-4896-83b4-5738d23bc4ba
0000116d-4255-427c-9319-a60170770d40
000032d2-3795-4b38-a222-b6599061b467
00004090-fbf1-4fd5-80cc-1f34d45af7a1
0000456e-1070-46c0-83e4-6fff495b89a3
00005b49-5266-405e-b4d3-d9a441bc38e3
000066c6-1184-47fc-acf6-916cb640c3f4
000099a6-d457-47fb-a274-63eb566bfd44
00012ac0-a893-41c7-a806-27728a1127e2
00013bea-4be2-4270-8efe-c00cd57b525d
当我跑的时候

diff -y file1.txt file2.txt
我得到了以下奇怪的结果:

0000075d-7f2c-4896-83b4-5738d23bc4ba                            0000075d-7f2c-4896-83b4-5738d23bc4ba
                                                              > 0000116d-4255-427c-9319-a60170770d40
                                                              > 000032d2-3795-4b38-a222-b6599061b467
                                                              > 00004090-fbf1-4fd5-80cc-1f34d45af7a1
                                                              > 0000456e-1070-46c0-83e4-6fff495b89a3
                                                              > 00005b49-5266-405e-b4d3-d9a441bc38e3
000066c6-1184-47fc-acf6-916cb640c3f4                            000066c6-1184-47fc-acf6-916cb640c3f4
0000913e-adf2-41be-b377-749bd656cbf5                          | 000099a6-d457-47fb-a274-63eb566bfd44
0000cb55-9b2c-42ea-af3e-87d2c7713c13                          <
00012ac0-a893-41c7-a806-27728a1127e2                            00012ac0-a893-41c7-a806-27728a1127e2
00013bea-4be2-4270-8efe-c00cd57b525d                            00013bea-4be2-4270-8efe-c00cd57b525d
00014c1d-6a5d-4c5e-aff0-a44cf49c54d5                          <
0001d18b-c5c8-41c4-bcb0-e3c8074cb39e                          <
00022848-b122-4c6a-b810-51737db09a5b                          <
00022b1e-0148-4dad-bb82-a9be457ed2e7                          <
我不确定这个输出是什么意思,因为它们是不同的,但是它们在同一条线上,中间有“π”。

如果有人知道原因,请告诉我

非常感谢。

请查看,其中提供了并排使用的标记的描述以及以下示例输出:

The Way that can be told of is n   <
The name that can be named is no   <
The Nameless is the origin of He        The Nameless is the origin of He
The Named is the mother of all t   |    The named is the mother of all t
                                   >
Therefore let there always be no        Therefore let there always be no
  so we may see their subtlety,           so we may see their subtlety,
And let there always be being,          And let there always be being,
  so we may see their outcome.            so we may see their outcome.
The two are the same,                   The two are the same,
But after they are produced,            But after they are produced,
  they have different names.              they have different names.
                                   >    They both may be called deep and
                                   >    Deeper and more profound,
                                   >    The door of all subtleties!
可以说是n<
可以命名的名称是no<
无名是他之源无名是他之源
被命名者是所有t的母亲
>
因此,让永远没有,因此,让永远没有
所以我们可以看到他们的微妙之处,所以我们可以看到他们的微妙之处,
让存在永远存在,让存在永远存在,
因此,我们可以看到他们的结果。因此,我们可以看到他们的结果。
两个一样,两个一样,,
但是在它们被生产之后,但是在它们被生产之后,
他们有不同的名字。他们有不同的名字。
>它们都可以被称为深沉的
>更加深刻,,
>所有微妙之处的大门!
|
标记基本上表示该行存在于两个文件中,但已被修改

在您的示例中,diffing算法确定该行上的两个文件之间的内容非常相似,因此它们表示同一行,并进行了修改

The Way that can be told of is n   <
The name that can be named is no   <
The Nameless is the origin of He        The Nameless is the origin of He
The Named is the mother of all t   |    The named is the mother of all t
                                   >
Therefore let there always be no        Therefore let there always be no
  so we may see their subtlety,           so we may see their subtlety,
And let there always be being,          And let there always be being,
  so we may see their outcome.            so we may see their outcome.
The two are the same,                   The two are the same,
But after they are produced,            But after they are produced,
  they have different names.              they have different names.
                                   >    They both may be called deep and
                                   >    Deeper and more profound,
                                   >    The door of all subtleties!