Skip to content

Find and remove duplicate media files by comparing decoded audio/video streams with ffmpeg — catches duplicates that differ only in metadata or filenames.

License

Notifications You must be signed in to change notification settings

elgorro/DeleteDuplicatedMediaFiles

Repository files navigation

Delete Duplicated Media Files

Find and remove duplicate media files by comparing their actual audio/video content — not just filenames or metadata.

Traditional duplicate finders hash the entire file, so two files with identical audio but different ID3 tags or filenames slip through. This tool uses ffmpeg's MD5 muxer to hash only the decoded media stream, catching duplicates that other tools miss.

Quick start

# Dry-run: find duplicates without deleting anything
./delete-media-duplicates.sh /path/to/media/

# Delete duplicates (keeps one copy of each)
./delete-media-duplicates.sh --delete /path/to/media/

# Verbose output
./delete-media-duplicates.sh --verbose /path/to/media/

Requirements

Options

Flag Description
--delete Remove duplicates (default is dry-run)
--verbose Show per-file processing details
--help Show usage information

Supported formats

Any format ffmpeg can decode: MP3, FLAC, WAV, OGG, AAC, MP4, AVI, MKV, and many more. Non-media files are skipped with a warning.

Documentation

See the docs/ folder for detailed guides:

  • Usage — full usage instructions and performance notes
  • Development — project structure and design decisions
  • Testing — running and extending the test suite

Acknowledgments

Built on the shoulders of two giants:

  • ffmpeg — the Swiss Army knife of media processing, making content-based hashing possible
  • Bash & the GNU/Linux coreutils — proving that shell scripts can still get serious work done

License

MIT

About

Find and remove duplicate media files by comparing decoded audio/video streams with ffmpeg — catches duplicates that differ only in metadata or filenames.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages