add a few checks in the batch script

git-svn-id: https://subtitleedit.googlecode.com/svn/trunk@171 99eadd0c-20b8-1223-b5c4-2a2b2df33de2
This commit is contained in:
XhmikosR 2010-11-29 16:27:13 +00:00
parent 3e74b7cc9f
commit cb2d2e1c3c

View File

@ -2,6 +2,8 @@
SETLOCAL SETLOCAL
TITLE Compiling Subtitle Edit... TITLE Compiling Subtitle Edit...
IF NOT DEFINED VS100COMNTOOLS ECHO:Visual Studio 2010 wasn't found&&GOTO :EndWithError
REM Detect if we are running on 64bit WIN and use Wow6432Node, and set the path REM Detect if we are running on 64bit WIN and use Wow6432Node, and set the path
REM of Inno Setup accordingly REM of Inno Setup accordingly
IF "%PROGRAMFILES(x86)%zzz"=="zzz" (SET "U_=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall" IF "%PROGRAMFILES(x86)%zzz"=="zzz" (SET "U_=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall"
@ -25,12 +27,16 @@ IF %ERRORLEVEL% NEQ 0 GOTO :EndWithError
ECHO. ECHO.
POPD POPD
IF DEFINED InnoSetupPath (
PUSHD "InnoSetupScript" PUSHD "InnoSetupScript"
"%InnoSetupPath%\iscc.exe" /Q "Subtitle_Edit_installer.iss" "%InnoSetupPath%\iscc.exe" /Q "Subtitle_Edit_installer.iss"
IF %ERRORLEVEL% NEQ 0 GOTO :EndWithError IF %ERRORLEVEL% NEQ 0 GOTO :EndWithError
ECHO.&&ECHO:Installer compiled successfully! ECHO.&&ECHO:Installer compiled successfully!
MOVE /Y "SubtitleEdit-*-setup.exe" ".." >NUL 2>&1 MOVE /Y "SubtitleEdit-*-setup.exe" ".." >NUL 2>&1
POPD POPD
) ELSE (
ECHO:Inno Setup wasn't found; the installer wasn't built
)
:END :END