organize icon indicating copy to clipboard operation
organize copied to clipboard

Merge folders upon conflict.

Open telometto opened this issue 3 years ago • 2 comments

Is your feature request related to a problem? Please describe. When targeting dirs, the possibility to merge folders if a folder with the same name exists in the destination dir.

Describe the solution you'd like The ability to merge folders upon conflict.

Describe alternatives you've considered I've tried doing so that for any conflicting folder, a number gets appended (I didn't get it to work, though).

Additional context x

telometto avatar Aug 10 '22 22:08 telometto

That sounds like a nice feature. It could become a bit complex because many things could be configured like

  • recursive merges (with depth limit?)
  • conflict options for the files inside the folder (skip, overwrite, rename, overwrite if newer, ...)

I've tried doing so that for any conflicting folder, a number gets appended (I didn't get it to work, though).

Can you share your use-case? Folder targeting is relatively new and not so well tested at the moment, it might be a bug.

tfeldmann avatar Aug 11 '22 09:08 tfeldmann

My use-case is basically this: any "loose" file found, gets put in a directory unsorted_<type> which, in turn, contains sub-folders based on extension and, therein, folders based on date. The unsorted_<type> folders are created in the same dir the file was found ({path.parent}/unsorted_vids/{extension.lower()}/{created.strftime('%Y-%m-%d')}/). Since the template is the same for every file/folder, I wanted to move every type (e.g. music, docs, etc.) to the location where it belongs, but it wouldn't allow me/organize reports that the folder exists in the dest dir.

For my use-case, it would be enough for me to have parent/subdir/subdir merged. I tried using rename: {name}{+1} but that (obviously) didn't work. If you got a way around it or some clever trick to just append a letter or a number to rename the dir upon conflict, that will do as well; I can then just manually move the sub-dirs where they belong 😊

E.g. Screenshot from 2022-08-11 13-02-44 Screenshot from 2022-08-11 13-03-01

telometto avatar Aug 11 '22 11:08 telometto