Many times it is important to record the current state of the file system or to compare the file system state before and after a program installation. By comparing snapshots from before and after a new program installation or execution, you can determine which files were added, changed, or deleted. The following batch file will achieve this result.
DIR c:\ /ON /S /A >before.txt
DIR c:\ /ON /S /S >after.txt
FC /L /LB9999 before.txt after.txt > difference.txt
The before and after DIR commands create a file containing a list of all files on the C: drive, including subdirectories and hidden files and alphabetized by file name. The last command creates new file containing the list of files that have been added, changed, or deleted.
Note that the intermediate snapshot files can be very large, especially for the large hard drives in modern computers. The PC Magazine utility INCTRL3 detects changes to the files system in much the same way. But it stores its snapshots in a space-conserving format.
INCTRL3 also tracks changes to the Registry, which is extremely important in Windows 95 and Windows NT. Just comparing the files before and after a program installation without tracking changes in the Registry is most likely not sufficient to detect problems created by the new installation.