topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • Tuesday March 19, 2024, 6:48 am
  • Proudly celebrating 15+ years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: DONE: Simple Duplicate Folder Finder  (Read 16734 times)

magician62

  • Supporting Member
  • Joined in 2011
  • **
  • Posts: 178
    • View Profile
    • Donate to Member
DONE: Simple Duplicate Folder Finder
« on: April 29, 2012, 06:07 AM »
There are many file finders out there, and many folder finders based on content, but I am looking for what should be something simple

I want to be able to automatically search defined locations,  for duplicate folder names, 1st level only, no recursion necessary.
Each duplicate is then prepended by a "+". There is no risk of collision as the searched folders can not have duplicates anyway.
There are currently over 12000 folders which are continually being added to


My concept
Define location by Windows library, or, Define location by Drive\Directory
If Windows library can be used, it already holds all the Drive\Directory locations, and if further locations are added to the library, they are effectively added automatically.

The locations can either be directly entered into a config file as they will in general, not change between sessions.

The minimum interface I can see is a start button and a finished notification

Where more than one instance of a filename exists , each gets prepended by a "+"

Example
Before
c:\My Search Folder1\Compare1
c:\My Search Folder1\Compare2
d:\My Search Folder2\Compare2
e:\My Search Folder3\Compare3

After
c:\My Search Folder1\Compare1
c:\My Search Folder1\+Compare2
d:\My Search Folder2\+Compare2
e:\My Search Folder3\Compare3

And that's it!

I am not looking for the major automation many utils provide, I am just looking for the folders the dupes may reside, so they can be physically checked. the "+" puts them at the top of the directory, and when physically checked, the duplicates not required are deleted, and the "+" removed from the remaining folder.
Why an I Magician62? Because Magician1 thru 61 were gone. :)

MilesAhead

  • Supporting Member
  • Joined in 2009
  • **
  • Posts: 7,736
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #1 on: April 30, 2012, 04:39 PM »
The only thing I found that looks like it may be close is this:

http://sourceforge.n...s/vfolderdups/files/

There's not much on description. I'm not going to install it to see exactly what it is. But it's a Windows installer so I'm assuming it's Win32 code.

Unless writing a file manager app most people aren't keen on providing code to delete folders/files. There's just too much potential for unhappiness with no real upside. I would try the freeware sites if this sourceforge utility is not it.


magician62

  • Supporting Member
  • Joined in 2011
  • **
  • Posts: 178
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #2 on: May 01, 2012, 11:30 AM »
Have to say, didn't like the Util, seemed to take ages installing. In fact it took longer to install/uninstall, than its actual life on the machine. Which sets the spider senses tingling :)

Unfortunately it doesn't seem to allow for multi drives, which is essential, but apparently can find duplicates if they are in different folders on the drive. Which as I know there are no duplicates on each drive, as all folders are in a single top level direcory, makes it pointless.

I have tried many duplicate finders over the years, though most look for exact dupes, and some patern matching. Unfortunately all those I have seen want you to process all the items in the list, rather than provide a simple tagging system so you can come back at a later time, or even share the load if networked.

The util I seek has no need to delete any folders or files, just rename them, (stick a "+" at the front)  I can do the deciding and deleting
Why an I Magician62? Because Magician1 thru 61 were gone. :)

MilesAhead

  • Supporting Member
  • Joined in 2009
  • **
  • Posts: 7,736
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #3 on: May 01, 2012, 02:27 PM »
I think you would have a better chance lobbying an existing file manager to add the feature. Also I took a look at working with the new Windows Seven Libraries. It's all COM based and a lot of work for a feature that will only work in Windows Seven. Pretty nasty spaghetti code.

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 5,286
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #4 on: May 01, 2012, 08:24 PM »
Just to clarify, this utility only needs to find and rename duplicate FOLDER names, right?  No FILE duplication matching whatsoever, correct?

If so, I've written a simple script that should do what you want but, obviously, it's only had minimal testing.

magician62

  • Supporting Member
  • Joined in 2011
  • **
  • Posts: 178
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #5 on: May 02, 2012, 12:25 PM »
Hi Jody, you got it. Its to find duplicate FOLDER names. I supply a number of locations across different drives, and ONLY those locatins need to be checked to see if they contain duplicate folders, no recursion needed. And the only action then is to add a + at the front which effectively gets the folders to the top of the list, which is in this case a Library view.

I then manually check contents, move from one folder to the other and delete whats unwanted, including the empty folder. I then manually remove the "+" from the folder
Why an I Magician62? Because Magician1 thru 61 were gone. :)

MilesAhead

  • Supporting Member
  • Joined in 2009
  • **
  • Posts: 7,736
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #6 on: May 02, 2012, 03:31 PM »
I always thought '+' sign was restricted as a file/folder name character. Apparently it is allowed. I just created a new folder named with a '+' at the start. But I am seeing a lot of stuff on the web about deleted files/folders that start with a plus not showing up in recycle bin, and other anomalies. It may be asking for trouble. Even though it's an allowed character, it's used for concatenation on the command line. It's bound to be misread by some software(likely Windows itself.)

edit: a leading underscore may accomplish the same thing without the bugs. _FolderName should float to the top.. unless you already have a bunch of folders with leading underscores.
« Last Edit: May 02, 2012, 03:42 PM by MilesAhead »

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 5,286
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #7 on: May 03, 2012, 11:27 AM »
This is done but, since it's such a custom request, I'm not sure if anybody else will be able to get any use out of it.

There is no GUI and you must manually create a folders.txt file with the paths you want scanned.  This folders.txt file is expected to be in the same folder as the main program executable.  A message box will pop up when it's done scanning and report how many dupes it found and renamed.  I'll post the archive here for posterity.   :D

http://skwire.dcmemb...gician62DupeTool.zip

magician62

  • Supporting Member
  • Joined in 2011
  • **
  • Posts: 178
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #8 on: May 03, 2012, 11:31 AM »
Many thanks as always for a simple, but sweet utility. Has saved me about 3 hours work every few days
Why an I Magician62? Because Magician1 thru 61 were gone. :)

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 5,286
    • View Profile
    • Donate to Member
Re: IDEA: Simple Duplicate Folder Finder
« Reply #9 on: May 03, 2012, 11:33 AM »
Many thanks as always for a simple, but sweet utility. Has saved me about 3 hours work every few days

You are very welcome.   :)