topbanner_forum
  *

avatar image

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

Login with username, password and session length
  • Thursday April 18, 2024, 4:13 pm
  • 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

Last post Author Topic: DONE: Sync folders by renaming files  (Read 25402 times)

4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 5,643
    • View Profile
    • Donate to Member
Re: DONE: Sync folders by renaming files
« Reply #25 on: June 06, 2013, 08:57 PM »
I guess we can get skwire to move the thread to Finished then  ;)

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 5,286
    • View Profile
    • Donate to Member
Re: DONE: Sync folders by renaming files
« Reply #26 on: June 07, 2013, 08:21 AM »
I guess we can get skwire to move the thread to Finished then  ;)

Done.  Really slick batch file work, too, 4wd.

TaoPhoenix

  • Supporting Member
  • Joined in 2011
  • **
  • Posts: 4,642
    • View Profile
    • Donate to Member
Re: DONE: Sync folders by renaming files
« Reply #27 on: June 07, 2013, 08:47 AM »

Hmm.

I liked this idea so I decided to give it a try. But I can't get it to work!
I get an error:
"Choice is not recognized as an internal or external command, operable program, or batch file."
What am I missing?

Tested on my slightly infamous Win XP system.

4wd

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 5,643
    • View Profile
    • Donate to Member
Re: DONE: Sync folders by renaming files
« Reply #28 on: June 07, 2013, 10:39 PM »
What am I missing?

choice  :)

MS in their infinite wisdom included the choice.com/choice.exe DOS command in all versions of Windows from 3.1 and DOS 6.x onwards except 2000 and XP.

You can grab the choice.com command from a set of DOS 6+ disks - I've attached it below for Windows x86 only.

Also, I'm sorry to say, v9 SHA-1 calculation doesn't work due to the lack of Delayed Expansion, (enabling limits using ! in filenames), so I'm writing a small hash program so I won't have to use fciv.exe which is why I have to use the for loop to get the value I want.
Why they couldn't just output the hash value without any fluff is beyond me.  :-\

So, I should have another v9 up with a separate hash program later today.

Done.  Really slick batch file work, too, 4wd.

Spoke too soon there - give me a couple of hours though  ;)

OK, back with v9.5:
  • No longer requires choice.com, so it should work OK on W2k and XP.
  • Now has a dedicated hash program so the SHA-1 comparison works properly, (put it in the same folder as the batch file).
  • Checks to see if the Source and Destination are the same, it'll exit if they are.
« Last Edit: June 08, 2013, 12:10 AM by 4wd »