A fast and simple command-line tool to scan directories and find duplicate files based on content, not names.
- Scans directories recursively
- Detects duplicate files using SHA256 hashing
- Optionally include/exclude file extensions
- Export results to JSON with
--output - Colourful terminal output for easier scanning
As a prerequisite, you should have the latest Go version installed.
git clone https://github.com/anthophobiac/dupefinder.git
cd dupefinder
go installdupefinder scan [path] [flags]| Flag | Description |
|---|---|
--include-ext |
Only scan files with these extensions (e.g. .jpg,.txt) |
--exclude-ext |
Exclude files with these extensions |
--output, -o |
Write duplicate results to a JSON file |
dupefinder scan ./Downloadsdupefinder scan ./Music --include-ext=.mp3,.flacdupefinder scan ./Logs --exclude-ext=.log,.tmpdupefinder scan ./Documents --output=dupes.jsonHashing files [======================>] 100%
Duplicate group (e3b0c442...):
./photos/image1.jpg
./backup/image1_copy.jpg
Duplicate group (9a0364b9...):
./docs/report.pdf
./archive/old_report.pdf