Duplicate Cleaner has the ability to be called from the Windows command line shell, or a batch (.BAT) file.
The following command line parameters are supported:
/register
Register the license key For example: /register XXXXXXXXXXX
/data
Set the data folder location For example: /data "d:\data" (See note about escaping backslashes)
/i [folder]
Specify a folder to include in the scan. Can be used more than once.
/ir [folder]
Specify a folder to include in the scan, and show remaining files for this folder. Can be used more than once.
/e [folder]
Specify a folder to exclude from the scan. Can be used more than once.
/load [scan state name]
Load the named scan state upon starting
/m or /mr
Set to Regular Mode
/mi
Set to Image Mode
/ma
Set to Audio Mode
/mv
Set to Video Mode
/nf
If loading a state, don't load the 'folders to scan' list from it.
/csv [output file name]
Automatically export the duplicate files list to a csv file once the scan has completed.
/csvf [output file name]
Automatically export the duplicate folders list to a csv file once the scan has completed.
/csvr [output file name]
Automatically export the remaining files list to a csv file once the scan has completed.
/default
Apply the default settings
/a or /scan
Automatically begin the scan
/c or /close
Automatically close Duplicate Cleaner once the scan has completed
Notes:
-
Unless changed by specifying a state file, Duplicate Cleaner will start with the most recently used settings.
-
File or folder names with spaces in should be surrounded by double-quote marks (")
-
Folders specified with /i, /ir or /e are added
in addition to any loaded in the state, unless the /nf flag is used.
-
In addition to the above, a folder name can be sent to Duplicate Cleaner with no switches, to enable usage with Windows features such as SendTo and Explorer shell integration.
-
If ending a folder name with a backslash and quote (e.g. "C:\data\" you need to escape the last backslash ("C:\data\\") or you will end up with a quote embedded in your folder name.
Examples:
DuplicateCleaner.exe /i C:\Data\Docs /i C:\Data\Other
Starts Duplicate Cleaner with the two named folders added.
DuplicateCleaner.exe /i C:\Data\Docs /e C:\Data\Docs\Temp
Starts Duplicate Cleaner with the named folder added, and the temp folder excluded.
DuplicateCleaner.exe /load "C:\Users\myusername\AppData\Roaming\DigitalVolcano\DuplicateCleaner\States\mystate.data" /scan /csv "c:\output\results.csv" /close
This will load the state called "mystate" run the scan, create an output results csv file and close the program.