PaulLereverend / NextcloudDuplicateFinder

Save some space by finding your duplicate files
GNU Affero General Public License v3.0
76 stars 16 forks source link

auto delete the duplicates #43

Open Goddard opened 2 years ago

Goddard commented 2 years ago

I just started a new nextcloud instance and this is very painful going through deleting everything.

Why not just delete all duplicates with 1 button?

PaulLereverend commented 2 years ago

In this case how would the app choose which files to delete ?

Goddard commented 2 years ago

I can only speak for myself, but I imagine my nextcloud photos as being completely managed by nextcloud. I know right now they don't really have enough features for logical structuring and the android app is not far enough along either, but for my use case, I don't care which duplicate it deletes. I just want to remove duplicates and keep 1 photo. So I don't care which one it deletes. Eventually I hope nextcloud becomes more powerful.

I know a lot of linux command line apps can find duplicates for me so that is another option of course, but just figured I would make that suggestion. Not sure if you have any extra meta information that is added to next cloud when you make the delete happen? Like if my android phone is uploading photos and duplicates are deleted from nextcloud does it just re-upload it? Sorry not exactly related, but this is what I am concerned with when using it. If you spend a ton of time manually deleting the photos by hand and they are just re-added that would kind of suck.

jshwrner commented 2 years ago

It looks like NextCloud creates a hash for each media item (I assume when it's uploaded). If this is actually happening the way I think it is (haven't had a chance to look into it yet), I'd be pretty trusting in this app's ability to remove duplicates automatically as each media item with the same hash is guaranteed (essentially) to be a duplicate. I'm in a position in which I possibly have 10's of thousands of duplicates that I'm manually going through. Don't get me wrong, this add-on is great but I think it would be even more beneficial if it could provide a way do it all automatically. I've barely given this thought, but off the top of my head you could:

Not saying any of these ideas would be the perfect solution but I like the idea of tossing ideas around as I'd be excited to see this functionality implemented. I can try to start digging into the code to see if anything better comes to mind. Regardless, thanks for this add-on!