Compares two directories and highlights: - Files found only in the first directory - Files with the same name in both directories but different contents.
Go to file
Deadly Headshot 470d2ebe7b Updated Readme with notice of migration
Repository migrated to Codeberg
2021-10-26 08:07:23 +08:00
cmpdir.c Updated copyright notice. 2019-05-12 17:50:55 +01:00
cmpdir.exe Updated copyright notice. 2019-05-12 17:50:55 +01:00
LICENCE.txt Wrote program based on https://github.com/dheadshot/ListToCSV (MIT Licence and my own work anyway) 2019-05-12 17:34:02 +01:00
README.MD Updated Readme with notice of migration 2021-10-26 08:07:23 +08:00

DHSC CompareDirs 1.0

Notice of Migration:

This repository has been migrated across to https://codeberg.org/dheadshot/CompareDirs (https://codeberg.org/dheadshot/CompareDirs.git). Please note that this instance of the repository will no longer be updated. Please use that URL instead.


Copyright (c) 2019 DHeadshot's Software Creations

MIT Licence

Twitter @DHeadshot

Some code taken from https://github.com/dheadshot/ListToCSV, (c) 2018 DHeadshot's Software Creations, MIT Licence.


Compares two directories and highlights:

  • Files found only in the first directory
  • Files with the same name in both directories but different contents.

Warning: does not highlight files that only exist in the second directory!


Usage:

cmpdir [-r] <target directory> <comparitive directory>
	-r	Goes through the directories recursively within the path.  
		Without this option, it compares only files in the specified 
		directory and not in subdirectories.
		Only recurses into directories present in both the paths
		specified!
	<target directory>	Specify the directory to search through.
	<comparitive directory>	Specify the directory to compare against.

To Compile:

With gcc (MinGW, CygWin, etc.)

gcc -c cmpdir.c
gcc -o cmpdir.exe cmpdir.o -lkernel32

With tcc (Tiny C Compiler)

tcc -c cmpdir.c
tcc -o cmpdir.exe cmpdir.o -lkernel32