Skip to content

hex0cter/delete-duplicates

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Delete Duplicate

A CLI command inspired by go-find-duplicates, used to delete any duplicated files on your disk.

How to use

install Go Find Duplicates

go install github.com/m-manu/go-find-duplicates@latest
export PATH="$PATH:$HOME/go/bin"
go-find-duplicates -o json {dir-1} {dir-2} ... {dir-n}

This generate a json file called duplicates-*.json

Install Delete Duplicate:

npm install -g delete-duplicates
delete-duplicates -j <duplicates.json> [-d] [-q] {dir-1} {dir-2} ... {dir-n}

Parameters:

Options:
  -j <duplicates.json> # The file generated by go-find-duplicates
  -d     delete files. By default it only print the files. Please
         double check before you use this flag.
  -q     quiet mode.
  dir-n  If the duplicated file is listed in any of these directory,
         the first one is preserved and rest will be deleted. If it
         not found in any of these directories, the first one will be
         preserved and rest will be deleted.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published