ling091 2009-1-2
参考: http://en.wikipedia.org/wiki/Microsoft_File_Compare
微软的操作系统从MS-DOS 3.30版就有文件比较命令,该命令等同于UNIX系统的命令:comm,cmp和diff。微软的文件比较命令可以比较文本文件或二进制文件,文本 文件可以是ASCII或Unicode编码,比较的结果输出在标准输出上,主要是给人看,难以被其他程序所使用。
文件比较命令说明:
fc or comp
- Compares two files or sets of files and displays the differences between them.
FC [/A] [/C] [/L] [/LBn] [/N] [/T] [/W] [/nnnn] [drive1:][path1]filename1 [drive2:][path2]filename2
FC /B [drive1:][path1]filename1 [drive2:][path2]filename2
/A Displays only first and last lines for each set of differences.
/B Performs a binary comparison.
/C Disregards the case of letters.
/L Compares files as ASCII text.
/LBn Sets the maximum consecutive mismatches to the specified number of lines.
/N Displays the line numbers on an ASCII comparison.
/T Does not expand tabs to spaces.
/W Compresses white space (tabs and spaces) for comparison.
/nnnn Specifies the number of consecutive lines that must match after a mismatch.
[drive1:][path1]filename1 Specifies the first file or set of files to compare.
[drive2:][path2]filename2 Specifies the second file or set of files to compare.[citation needed
]
-
-
-
comp命令和fc命令使用起来并不一样,comp命令只给出文件基本信息的不同之处,如文件大小,而fc命令则会输出文件的不同之处。
-