LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-05-2023, 07:18 PM   #1
ericlindellnyc
Member
 
Registered: Jun 2017
Posts: 181

Rep: Reputation: Disabled
RMLINT -- move files instead of deleting them


I'm using RMLINT as a substitute for DUPEGURU, which is CPU- and RAM-intensive. However, RMLINT doesn't give me the option of moving duplicate files to a new folder instead of deleting them -- a feature that DUPEGURU has and which I can't find on any command-line script.
This is important, especially when I'm new to RMLINT, to avoid accidental erasures by keeping duplicates for a while before deleting.

I see a feature request from 2017, though I don't know if it's been implemented.
It's hard to find a command-line script that does all I need, including
searching for duplicate files or folders
only matches with the same name
using a reference folder
selecting file types to delete by extension
dry runs
moving duplicate hierarchy to separate folder

Last edited by ericlindellnyc; 12-05-2023 at 07:22 PM. Reason: addition
 
Old 12-05-2023, 07:29 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,142

Rep: Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123Reputation: 4123
Never used it (there are a plethora of CLI tools out there), but their own doco states:
Quote:
rmlint itself WILL NOT DELETE ANY FILES. It does however produce executable output (for example a shell script) to help you delete the files if you want to.
Most of the (useful) tools do likewise. It's just a script, hack it to your needs.

Edit: Missed the update as I was off looking for the doco. Get a tool that does most of what you want, and then manage it in the script. All the heavy lifting should be done for you.

Last edited by syg00; 12-05-2023 at 07:35 PM.
 
Old 12-05-2023, 09:31 PM   #3
ericlindellnyc
Member
 
Registered: Jun 2017
Posts: 181

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by syg00 View Post
Never used it (there are a plethora of CLI tools out there), but their own doco states:Most of the (useful) tools do likewise. It's just a script, hack it to your needs.

Edit: Missed the update as I was off looking for the doco. Get a tool that does most of what you want, and then manage it in the script. All the heavy lifting should be done for you.
That's a good idea. The rm command in the output file can be replaced with mv. But it helps to move the entire directory structure of duplicate files -- as dupeguru does. Dupeguru does everything I need, except it's so RAM/CPU-hungry that I can use it only on limited numbers of files.

I don't trust any script, app, or myself for that matter -- to handle this without error, which is why I insist on moving the files instead of deleting -- at least for a while.

I believe dupeguru does byte-for-byte comparison, which could account for its inefficiency. I can't find a switch to use only the hashing algorithm.

Thanks for your reply.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
list directories where all foles are dumpicated (rmlint) funkytwig Linux - General 6 04-01-2019 02:15 PM
LXer: Make “rm” Command To Move The Files To “Trash Can” Instead Of Removing Them Completely LXer Syndicated Linux News 0 10-11-2017 11:30 PM
rmlint-2.0.0 - a lint/duplicate finder [rewrite of old rmlint, testers wanted] sahib_bommelig Linux - General 13 10-25-2015 09:55 AM
del command to remove files to directory instead of completly deleting them. bettsy583 Linux - Newbie 1 12-02-2010 04:30 PM
[SOLVED] Bash script: how to move files to Trash instead of deleting? KonfuseKitty Programming 1 07-10-2010 12:44 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration