Windows Command Prompt TutorialIntroduction Internal and External commands Basic Commands Basic file commands Sorting the data Searching patterns in file Comparing files Variables in Windows command prompt Piping Input and Output Redirection View all processes and tasks killing tasks scheduling tasks Network commands System hardware commands
Comparing files in windows command promptcomp command is used to compare 2 or more files. Here is the syntax of comp command.
To make the file comparsion in case-insensitive way, you can use below command.
comp <file1> <file2>
comp command does not tell exact differences between files. We have another command “fc” that tells exact differences between files.Below image shows how “fc” command works.To ignore the case and print line number as well, you can use below command.
comp <file1> <file2> /c
fc names.txt names1.txt /N /C
Web development and Automation testing