Windows Vista Forums

Sleep affecting length of runtime for subversion sync

  1. #1


    babberoo Guest

    Sleep affecting length of runtime for subversion sync

    I've got a vbs script that runs through a list of entries in a text
    file and runs a subversion sync. My problem is that if I run the
    commands called in my script on the command line, they execute
    normally. However, if I run them in the script, they take forever to
    execute. Can anyone spot why the scripted version takes so long?

    The script should output the output from the commands back to the
    user, along with a "." progress meter.

    Set objFSO = CreateObject("Scripting.FileSystemObject")
    Set objTextFile = objFSO.OpenTextFile("C:\subversion_backup
    \repolist.conf", 1)
    Do Until objTextFile.AtEndOfStream
    wscript.echo("Starting: " & repo )
    repo = objTextFile.Readline
    wscript.echo("C:\Program Files\VisualSVN Server\bin
    \svnsync.exe init
    http://url.com/" & repo & " http://DEV:8080/svn/" &
    repo)
    Set oWsc = CreateObject("WScript.Shell")
    Set oExec = oWsc.Exec("C:\Program Files\VisualSVN Server\bin
    \svnsync.exe init http://url.com/" & repo & "
    http://DEV:8080/svn/" & repo)
    wscript.echo "Initialising..."
    Do While oExec.Status <> 1
    Wscript.sleep 10000
    wscript.stdout.write "."
    Loop
    wscript.stdout.write(oExec.stdout.ReadAll())
    Set oExec = Nothing



    Set oExec = oWsc.Exec("C:\Program Files\VisualSVN Server\bin
    \svnsync.exe --non-interactive sync http://url.com/"
    & repo)
    wscript.echo "Syncing..."
    Do While oExec.Status <> 1
    Wscript.sleep 10000
    wscript.stdout.write "."
    Loop
    wscript.stdout.write(oExec.stdout.ReadAll())
    Set oExec = Nothing
    wscript.echo("Completed: " & repo)
    Loop

      My System SpecsSystem Spec

  2. #2


    Csaba Gabor Guest

    Re: Sleep affecting length of runtime for subversion sync

    I haven't looked at your code in detail,
    but do you realize that you are telling the script
    to do nothing for 10 seconds when you call
    WScript.Sleep 10000 ? 10000milliseconds = 10seconds
    See, for example, http://www.ss64.com/wsh/sleep.html

    Csaba Gabor from Vienna

    On Mar 6, 10:19 am, "babbe...@xxxxxx"
    <babbe...@xxxxxx> wrote:

    > I've got a vbs script that runs through a list of entries in a text
    > file and runs a subversion sync. My problem is that if I run the
    > commands called in my script on the command line, they execute
    > normally. However, if I run them in the script, they take forever to
    > execute. Can anyone spot why the scripted version takes so long?
    >
    > The script should output the output from the commands back to the
    > user, along with a "." progress meter.
    >
    > Set objFSO = CreateObject("Scripting.FileSystemObject")
    > Set objTextFile = objFSO.OpenTextFile("C:\subversion_backup
    > \repolist.conf", 1)
    > Do Until objTextFile.AtEndOfStream
    > wscript.echo("Starting: " & repo )
    > repo = objTextFile.Readline
    > wscript.echo("C:\Program Files\VisualSVN Server\bin
    > \svnsync.exe inithttp://url.com/" & repo & "http://DEV:8080/svn/" &
    > repo)
    > Set oWsc = CreateObject("WScript.Shell")
    > Set oExec = oWsc.Exec("C:\Program Files\VisualSVN Server\bin
    > \svnsync.exe inithttp://url.com/" & repo & "http://DEV:8080/svn/" & repo)
    > wscript.echo "Initialising..."
    > Do While oExec.Status <> 1
    > Wscript.sleep 10000
    > wscript.stdout.write "."
    > Loop
    > wscript.stdout.write(oExec.stdout.ReadAll())
    > Set oExec = Nothing
    >
    > Set oExec = oWsc.Exec("C:\Program Files\VisualSVN Server\bin
    > \svnsync.exe --non-interactive synchttp://url.com/"
    > & repo)
    > wscript.echo "Syncing..."
    > Do While oExec.Status <> 1
    > Wscript.sleep 10000
    > wscript.stdout.write "."
    > Loop
    > wscript.stdout.write(oExec.stdout.ReadAll())
    > Set oExec = Nothing
    > wscript.echo("Completed: " & repo)
    > Loop

      My System SpecsSystem Spec

  3. #3


    gimme_this_gimme_that Guest

    Re: Sleep affecting length of runtime for subversion sync

    Try doing an SVN commit on your file instead of a doing a sync on the
    entire SVN project.

      My System SpecsSystem Spec

Sleep affecting length of runtime for subversion sync

Similar Threads
Thread Thread Starter Forum Replies Last Post
new router affecting mail caradee Vista mail 2 16 Aug 2009
Microsoft VBScript runtime error: Object doesn't support this property or method: 'WScript.Sleep' Mark Dougherty VB Script 8 19 Nov 2008
Disk Defrag affecting Sleep Function Bruce UK Vista performance & maintenance 9 01 Apr 2007
Disk Defrag affecting Sleep Function Bruce UK Vista General 9 01 Apr 2007
Tortoise for Subversion restarts Windows Explorer Remo Vista installation & setup 0 02 Feb 2007