Changeset 1245 for branches/sandbox


Ignore:
Timestamp:
Dec 17, 2013 10:03:01 AM (7 years ago)
Author:
toby
Message:

dup updates in trunk

Location:
branches/sandbox
Files:
2 added
1 edited

Legend:

Unmodified
Added
Removed
  • branches/sandbox/gsascmds.tcl

    r1226 r1245  
    37883788    return 0
    37893789}
     3790proc ChangeSVNserver {} {
     3791    if [file exists [file join $::expgui(gsasdir) proxyinfo.txt]] {
     3792        set fp [open [file join $::expgui(gsasdir) proxyinfo.txt]]
     3793        gets $fp proxaddr
     3794        gets $fp proxport
     3795        set proxy "--config-option servers:global:http-proxy-host=$proxaddr"
     3796        set proxp "--config-option servers:global:http-proxy-port=$proxport"
     3797        close $fp
     3798    } else {
     3799        set proxy {}
     3800        set proxp {}
     3801    }
     3802    set SVN [auto_execok svn]
     3803    set res {}
     3804    catch {set res \
     3805               [eval exec $SVN info $::expgui(gsasdir)] \
     3806           } err
     3807    if {[string first .xor.aps $res] != -1} {
     3808        puts "Switching to .xray.aps"
     3809        eval exec $SVN switch \
     3810            [list "--relocate" \
     3811                 "https://subversion.xor.aps.anl.gov/EXPGUI" \
     3812                 "https://subversion.xray.aps.anl.gov/EXPGUI" \
     3813                 $::expgui(gsasdir) ] $proxy $proxp
     3814    }
     3815}
     3816
    37903817
    37913818proc CheckAndDoUpdate { } {
     
    38173844        return
    38183845    }
     3846    # migrate to new server, if needed
     3847    ChangeSVNserver
    38193848    # check for updates
    38203849    set SVN [auto_execok svn]
Note: See TracChangeset for help on using the changeset viewer.