What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal
RebornBuddy Forums

Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

SVN Update/batch help

cn.

New Member
Joined
Aug 15, 2011
Messages
71
FOR %%A IN (
"1"
"2"
"3"
) DO START TortoiseProc.exe /path:%%A

executes as
TortoiseProc.exe /path:"1"
TortoiseProc.exe /path:"2"
TortoiseProc.exe /path:"3"

I need it to execute all folders at once so that only one svn window opens rather than one for each folder
 
Last edited:
Try this:
@echo off
set projects=""
FOR %%project IN (
"C:\Program Files (x86)\Zend\Apache2\htdocs\Project0"
"C:\Program Files (x86)\Zend\Apache2\htdocs\Project1"
"C:\Program Files (x86)\Zend\Apache2\htdocs\Project2"
"C:\Program Files (x86)\Zend\Apache2\htdocs\Project3"
"C:\Program Files (x86)\Zend\Apache2\htdocs\Project4"
) DO CALL :CONCAT %%project
TortoiseProc.exe /command:update /path:"%projects:"=%" /closeonend:0;
goto :eof

:CONCAT
set projects=%projects%%1*
goto :eof

The reasoning behind this is that instead of launching a single instance of the updater for each folder, like this
TortoiseProc.exe /path:"1"
TortoiseProc.exe /path:"2"
TortoiseProc.exe /path:"3"

You actually group up all the folders you want to update into one single reference, and then run a single instance of the updater, for that reference. Like this:
DO CALL :CONCAT %%project
TortoiseProc.exe /command:update /path:"%projects:"=%" /closeonend:0;

The only thing you would have to replace are the file locations, obviously.
The difference is the :CONCAT command which assembles are your update windows into one.

http://planetozh.com/blog/?p=1032&cp=1#comment-199653

Let us know if it works :)

Greets,
Nab
 
Just tried it and I got "%project was unexpected at this time." as well
 
this worked

@echo off
SET A=""
FOR %%A IN (
"E:\HB Releases\HB - Bots\AutoAngler2"
"E:\HB Releases\HB - Bots\BgBot"
"E:\HB Releases\HB - Bots\Professionbuddy"
"E:\HB Releases\HB - Bots\Tyrael"
"E:\HB Releases\HB - CC\Demonic"
"E:\HB Releases\HB - CC\Fury Unleashed"
"E:\HB Releases\HB - CC\king-wow"
"E:\HB Releases\HB - CC\PureRotation"
"E:\HB Releases\HB - CC\TuanHADK"
"E:\HB Releases\HB - CC\TuanHAHunter"
"E:\HB Releases\HB - CC\TuanHAMonk"
"E:\HB Releases\HB - CC\TuanHAPaladin"
"E:\HB Releases\HB - CC\TuanHARogue"
"E:\HB Releases\HB - CC\TuanHAShadowPriest"
"E:\HB Releases\HB - CC\TuanHAShaman"
"E:\HB Releases\HB - Profiles\HB - Kick's Profiles"
"E:\HB Releases\HB - Plugins\AeonaxxCatcher"
"E:\HB Releases\HB - Plugins\AlwaysHere"
"E:\HB Releases\HB - Plugins\Jumpy"
"E:\HB Releases\HB - Plugins\Gatherbro"
"E:\HB Releases\HB - Plugins\IWantMovement"
"E:\HB Releases\HB - Plugins\LogMeOut"
"E:\HB Releases\HB - Plugins\MrItemRemover2"
"E:\HB Releases\HB - Plugins\Rarekiller"
"E:\HB Releases\HB - Plugins\TidyBags"
"E:\HB Releases\HB - Plugins\Ultimate PVP"
) DO CALL :CONCAT %%A
TortoiseProc.exe /command:update /path:"%A:"=%" /closeonend:1;
goto :eof

:CONCAT
set A=%A%%1*
goto :eof
 

Attachments

@echo off
FOR %%A IN (
"C:\Users\lola\Desktop\WoW\Honorbuddy\Default Profiles\kicks-scripts"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\CLU"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\king-wow"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\Superbad"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHADK"
"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHAHunter"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHAHunterSpecialEdition"
"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHADKSpecialEdition"
"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHAMonkSpecialEdition"
"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHARogueSpecialEdition"
"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\TuanHAPaladinSpecialEdition"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\Demonic"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\Purerotation"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\RichieShadowPriest"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Routines\RichieDiscPriestPvP"

"C:\Users\lola\Desktop\WoW\Honorbuddy\Bots\Tyrael"

) DO START TortoiseProc.exe /command:update /path:%%A /closeonend:2

^^ thats mine
 
it opens them all for me -.^

i think there may be a 255 char limit in the concatenated version. (8192 characters apparently) , it is a lot neater, but for me it's terribly slow, even with 4 folders or 40 folders.

also for people who have a ton of SVN's, and don't have an idea of how to make a list,
here's a short way to get a list of folders

Code:
for /d /r %%f in (*) do (
if exist %%f\.svn (
echo "%%f" >>%userprofile%\Desktop\SVNfolders.txt
)
)

save this as a batch file,
run it from the folder you store your bots in, be it Documents or Downloads, Bots, C:\ or G:\,
drag the batch file into the main folder, and it will save a list to the desktop.

it will just look for the folders, and put them in a text file on your desktop you can paste into the above batch files.

2nd part, if you want to add a bit of a pause, you can modify the above to do this ...

in windows 7 or 8, you can use

timeout /T 10 /NOBREAK

for everyone else, there's Ping.

Code:
@echo off
echo Updating Honorbuddy SVN folders
echo ========================
echo
echo . Profiles
rem
FOR %%Profiles IN (
""
"folders go here"
) DO START TortoiseProc.exe /command:update /path:%%Profiles /closeonend:2
rem Adding a 7 second break to let those windows close. more than likely, you can extend this to 10 or 15 or 20, just to minimise the BLAM.
rem
rem you can change this if you want them to move along faster, use a number higher than 2, or just remove the ping command.
rem
ping -n 8 localhost >nul 2>&1
rem
echo .. Bots
FOR %%Bots IN (
         " put all the bots folders with SVN in here"
) DO START TortoiseProc.exe /command:update /path:%%Bots /closeonend:2
rem
ping -n 8 localhost >nul 2>&1
echo ... Combat Routines
FOR %%CR IN (
         " put the list of folders with combat routines here"
) DO START TortoiseProc.exe /command:update /path:%%CR /closeonend:1
rem
ping -n 8 localhost >nul 2>&1
echo .... Plugins
FOR %%PLUG IN (
         " put folders for each plugin SVN here"
) DO START TortoiseProc.exe /command:update /path:%%PLUG /closeonend:1
rem
echo Done.
exit
 
@echo off
SET A=""
FOR %%A IN (
"Path"
) DO CALL :CONCAT %%A
TortoiseProc.exe /command:update /path:"%A:"=%" /closeonend:1;
goto :eof

:CONCAT
set A=%A%%1*
goto :eof
One of the most useful batch scripts ever made. Thank you.
 
Is there a way to have these print a log file? I haven't been able to get these to work.
 
Back
Top