Forrest logo
back to the comp tool

comp:tldr:4ccd3

comp: Display differences in decimal format.
$ comp /d ${path\to\file1} ${path\to\file2}
try on your machine

The command "comp /d ${path\to\file1} ${path\to\file2}" is used to compare two files and display the differences between them. Here is the breakdown of the command:

  • "comp" is the command to compare files in Windows command prompt.
  • "/d" is an option for the comp command, which tells it to perform a binary comparison of the files to identify differences.
  • "${path\to\file1}" is the placeholder for the full path to the first file you want to compare. You need to replace "${path\to\file1}" with the actual path to the file.
  • "${path\to\file2}" is the placeholder for the full path to the second file you want to compare. You need to replace "${path\to\file2}" with the actual path to the file.

Once you replace the placeholders with the actual paths to the files, executing this command will compare the two specified files and display any differences found.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the comp tool