Changeset 55bbe0b2 in sasview for build_tools
- Timestamp:
- Aug 19, 2016 4:51:09 AM (8 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 09afe90
- Parents:
- 1686a333
- git-author:
- Piotr Rozyczko <rozyczko@…> (08/19/16 04:50:48)
- git-committer:
- Piotr Rozyczko <rozyczko@…> (08/19/16 04:51:09)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
build_tools/sasview_deploy_test.au3
r1cecc91 r55bbe0b2 6 6 ; 7 7 ; 0 - OK 8 ; 1 - Download failure 9 ; 2 - Installer failure 10 ; 3 - Problems running SasView (simple fitting) 11 ; 4 - Uninstaller failure 8 ; 1 - Installer failure 9 ; 2 - Problems running SasView (simple fitting) 10 ; 3 - Uninstaller failure 12 11 13 12 #include <Constants.au3> 14 13 #include <FileConstants.au3> 15 14 #include <MsgBoxConstants.au3> 16 #include <InetConstants.au3>17 15 #include <WinAPIFiles.au3> 18 16 19 ; Custom error handler20 ;Global $oMyError = ObjEvent("AutoIt.Error","MyErrFunc")21 22 17 ; Modifiable globals 23 if $CmdLine[0] == 0 Then 24 ; Expected command line with the build number as argument 25 Exit (-1) 18 Global $fInstallerLocation = @TempDir & "\setupSasView.exe" 19 if $CmdLine[0] > 0 Then 20 ; If argument present - use it as local download path 21 $fInstallerLocation = $CmdLine[1] 26 22 EndIf 27 23 28 Local $lBuildNumber = $CmdLine[1]29 ;Global $fInstallerLocation = "C:\util\setupSasView.exe" ; debug and testing location30 Global $fInstallerLocation = @TempDir & "\setupSasView.exe"31 Global $fRemoteInstallerLocation = "https://jenkins.esss.dk/sasview/job/SasView_Win7_Test/" & $lBuildNumber & "/artifact/sasview/dist/setupSasView.exe"32 24 Global $fUninstallerLocation = "C:\Program Files (x86)\SasView\unins000.exe" 33 25 Global $lTimeout = 10 ; 10 sec timeout for waiting on windows … … 37 29 Global $installerPID = 0 38 30 39 40 31 ;; MAIN SCRIPT 41 Download()42 32 Install() 43 33 RunSasView() 44 34 Uninstall() 45 46 35 Exit(0) 47 36 48 37 ;============================================================== 49 Func Download()50 ; Download the file in the background with the selected option of 'force a reload from the remote site.'51 ConsoleWrite("Downloading...." & @CRLF)52 Local $iFailFlag = 153 Local $hDownload = InetGet($fRemoteInstallerLocation, $fInstallerLocation, $INET_FORCERELOAD)54 55 ; Close the handle returned by InetGet.56 InetClose($hDownload)57 Assert($hDownload, $iFailFlag)58 ConsoleWrite("Installer downloaded successfully to " & $fInstallerLocation & @CRLF)59 60 EndFunc61 38 62 39 Func Install() 63 40 ;;;;; APPLICATION INSTALLED ;;;;;;; 64 41 Local $sSetupWindow = "Setup - SasView" 65 Local $iFailFlag = 242 Local $iFailFlag = 1 66 43 ; Run setup 67 44 if FileExists($fInstallerLocation) Then … … 75 52 76 53 ; License click through 77 WinActivate($sSetupWindow) ; <-- REQUIRED when connecting from another host54 WinActivate($sSetupWindow) 78 55 Local $test = WinWaitActive($sSetupWindow, "License Agreement", $lTimeout) 79 56 ;ConsoleWrite("license agreement: " & $test)
Note: See TracChangeset
for help on using the changeset viewer.