1
votes

I'm writing an Inno Setup installer which requires me to do some command prompt work. I need to navigate to a directory, call a batch file with a parameter 'setupDecompWorkspace' and then I'd like to be able to watch it run.

I'm currently doing it this way:

[Run]
Filename:"E:\Project\forge_src\gradlew.bat";Parameters:"/setupDecompWorkspace"

However that isn't working. After this command I would need to do another run of that same batch file with another parameter. As a new approach I tried building my own batch file which did all of this. When I run that batch file from my folder it works fine however Inno Setup is giving an exit code of 1 and refuses to start. It do this I was using:

[Run]
Filename: "E:\Project\forge_src\gradle.bat";

Could anyone point me in the right direction of what I'm doing wrong? I've been able to do it successfully in the command prompt as well as through executing my own batch file but any implementation in Inno Setup is giving me trouble.

Here is the full program:

#define MyAppName "Project"
#define MyAppVersion "1.0"
#define MyAppPublisher "Project"
#define MyAppURL "http://www.project.com/"
#define MyAppExeName "project.exe"

[Setup]

AppId={{0E56B9DD-F0FE-400D-9BB3-9082C5ECD73B}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
OutputBaseFilename=setup
Compression=lzma
SolidCompression=yes
PrivilegesRequired = admin
SetupLogging = yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Files]
Source: "E:\Project\*.*"; DestDir: "C:\Program Files (x86)\Project"; Flags: recursesubdirs

[Run]
Filename: "E:\Project\installers\gradle.bat";

Here is the log file it is creating:

2015-04-16 12:55:55.681   Log opened. (Time zone: UTC-07:00)
2015-04-16 12:55:55.681   Setup version: Inno Setup version 5.5.5 (a)
2015-04-16 12:55:55.682   Original Setup EXE: E:\Project\installers\Output\setup.exe
2015-04-16 12:55:55.683   Setup command line: /SL5="$20498,262866,56832,E:\Project\installers\Output\setup.exe" /SPAWNWND=$10496 /NOTIFYWND=$1048A /DEBUGWND=$10474 
2015-04-16 12:55:55.684   Windows version: 6.1.7601 SP1  (NT platform: Yes)
2015-04-16 12:55:55.685   64-bit Windows: Yes
2015-04-16 12:55:55.686   Processor architecture: x64
2015-04-16 12:55:55.686   User privileges: Administrative
2015-04-16 12:55:55.689   64-bit install mode: No
2015-04-16 12:55:55.694   Created temporary directory: C:\Users\Laptop\AppData\Local\Temp\is-N6J75.tmp
2015-04-16 12:56:04.483   Starting the installation process.
2015-04-16 12:56:04.487   Creating directory: C:\Program Files (x86)\Project
2015-04-16 12:56:04.489   Directory for uninstall files: C:\Program Files (x86)\Project
2015-04-16 12:56:04.491   Creating new uninstall log: C:\Program Files (x86)\Project\unins000.dat
2015-04-16 12:56:04.500   -- File entry --
2015-04-16 12:56:04.502   Dest filename: C:\Program Files (x86)\Project\unins000.exe
2015-04-16 12:56:04.508   Time stamp of our file: 2015-04-16 12:55:55.588
2015-04-16 12:56:04.510   Installing the file.
2015-04-16 12:56:04.517   Uninstaller requires administrator: Yes
2015-04-16 12:56:04.558   Successfully installed the file.
2015-04-16 12:56:04.560   -- File entry --
2015-04-16 12:56:04.564   Dest filename: C:\Program Files (x86)\Project\forge_src\build.gradle
2015-04-16 12:56:04.566   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.567   Installing the file.
2015-04-16 12:56:04.568   Creating directory: C:\Program Files (x86)\Project\forge_src
2015-04-16 12:56:04.586   Successfully installed the file.
2015-04-16 12:56:04.587   -- File entry --
2015-04-16 12:56:04.589   Dest filename: C:\Program Files (x86)\Project\forge_src\CREDITS-fml.txt
2015-04-16 12:56:04.591   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.592   Installing the file.
2015-04-16 12:56:04.605   Successfully installed the file.
2015-04-16 12:56:04.608   -- File entry --
2015-04-16 12:56:04.609   Dest filename: C:\Program Files (x86)\Project\forge_src\forge-1.7.10-10.13.2.1230-changelog.txt
2015-04-16 12:56:04.611   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.612   Installing the file.
2015-04-16 12:56:04.636   Successfully installed the file.
2015-04-16 12:56:04.637   -- File entry --
2015-04-16 12:56:04.639   Dest filename: C:\Program Files (x86)\Project\forge_src\gradlew
2015-04-16 12:56:04.641   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.642   Installing the file.
2015-04-16 12:56:04.652   Successfully installed the file.
2015-04-16 12:56:04.653   -- File entry --
2015-04-16 12:56:04.655   Dest filename: C:\Program Files (x86)\Project\forge_src\gradlew.bat
2015-04-16 12:56:04.657   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:04.658   Installing the file.
2015-04-16 12:56:04.667   Successfully installed the file.
2015-04-16 12:56:04.669   -- File entry --
2015-04-16 12:56:04.670   Dest filename: C:\Program Files (x86)\Project\forge_src\LICENSE-fml.txt
2015-04-16 12:56:04.671   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:04.673   Installing the file.
2015-04-16 12:56:04.684   Successfully installed the file.
2015-04-16 12:56:04.686   -- File entry --
2015-04-16 12:56:04.688   Dest filename: C:\Program Files (x86)\Project\forge_src\MinecraftForge-Credits.txt
2015-04-16 12:56:04.689   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:04.690   Installing the file.
2015-04-16 12:56:04.701   Successfully installed the file.
2015-04-16 12:56:04.702   -- File entry --
2015-04-16 12:56:04.704   Dest filename: C:\Program Files (x86)\Project\forge_src\MinecraftForge-License.txt
2015-04-16 12:56:04.705   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:04.707   Installing the file.
2015-04-16 12:56:04.717   Successfully installed the file.
2015-04-16 12:56:04.720   -- File entry --
2015-04-16 12:56:04.721   Dest filename: C:\Program Files (x86)\Project\forge_src\README.txt
2015-04-16 12:56:04.723   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:04.724   Installing the file.
2015-04-16 12:56:04.732   Successfully installed the file.
2015-04-16 12:56:04.734   -- File entry --
2015-04-16 12:56:04.735   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\gradle.log
2015-04-16 12:56:04.737   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.738   Installing the file.
2015-04-16 12:56:04.739   Creating directory: C:\Program Files (x86)\Project\forge_src\.gradle
2015-04-16 12:56:04.746   Successfully installed the file.
2015-04-16 12:56:04.748   -- File entry --
2015-04-16 12:56:04.749   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\cache.properties
2015-04-16 12:56:04.751   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.752   Installing the file.
2015-04-16 12:56:04.753   Creating directory: C:\Program Files (x86)\Project\forge_src\.gradle\2.0
2015-04-16 12:56:04.754   Creating directory: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts
2015-04-16 12:56:04.764   Successfully installed the file.
2015-04-16 12:56:04.766   -- File entry --
2015-04-16 12:56:04.768   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\cache.properties.lock
2015-04-16 12:56:04.769   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.770   Installing the file.
2015-04-16 12:56:04.779   Successfully installed the file.
2015-04-16 12:56:04.780   -- File entry --
2015-04-16 12:56:04.782   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\fileHashes.bin
2015-04-16 12:56:04.783   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.784   Installing the file.
2015-04-16 12:56:04.797   Successfully installed the file.
2015-04-16 12:56:04.798   -- File entry --
2015-04-16 12:56:04.800   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\fileSnapshots.bin
2015-04-16 12:56:04.801   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.802   Installing the file.
2015-04-16 12:56:04.815   Successfully installed the file.
2015-04-16 12:56:04.817   -- File entry --
2015-04-16 12:56:04.819   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\outputFileStates.bin
2015-04-16 12:56:04.820   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.822   Installing the file.
2015-04-16 12:56:04.837   Successfully installed the file.
2015-04-16 12:56:04.840   -- File entry --
2015-04-16 12:56:04.842   Dest filename: C:\Program Files (x86)\Project\forge_src\.gradle\2.0\taskArtifacts\taskArtifacts.bin
2015-04-16 12:56:04.843   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.845   Installing the file.
2015-04-16 12:56:04.855   Successfully installed the file.
2015-04-16 12:56:04.858   -- File entry --
2015-04-16 12:56:04.860   Dest filename: C:\Program Files (x86)\Project\forge_src\build\.gitignore
2015-04-16 12:56:04.861   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.863   Installing the file.
2015-04-16 12:56:04.865   Creating directory: C:\Program Files (x86)\Project\forge_src\build
2015-04-16 12:56:04.875   Successfully installed the file.
2015-04-16 12:56:04.877   -- File entry --
2015-04-16 12:56:04.879   Dest filename: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\GradleStart.java
2015-04-16 12:56:04.881   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.882   Installing the file.
2015-04-16 12:56:04.884   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp
2015-04-16 12:56:04.886   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart
2015-04-16 12:56:04.888   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted
2015-04-16 12:56:04.905   Successfully installed the file.
2015-04-16 12:56:04.907   -- File entry --
2015-04-16 12:56:04.910   Dest filename: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\GradleStartServer.java
2015-04-16 12:56:04.911   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.913   Installing the file.
2015-04-16 12:56:04.925   Successfully installed the file.
2015-04-16 12:56:04.927   -- File entry --
2015-04-16 12:56:04.929   Dest filename: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\net\minecraftforge\gradle\GradleStartCommon.java
2015-04-16 12:56:04.931   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.932   Installing the file.
2015-04-16 12:56:04.935   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\net
2015-04-16 12:56:04.937   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\net\minecraftforge
2015-04-16 12:56:04.939   Creating directory: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\net\minecraftforge\gradle
2015-04-16 12:56:04.953   Successfully installed the file.
2015-04-16 12:56:04.955   -- File entry --
2015-04-16 12:56:04.958   Dest filename: C:\Program Files (x86)\Project\forge_src\build\tmp\makeStart\extracted\net\minecraftforge\gradle\OldPropertyMapSerializer.java
2015-04-16 12:56:04.960   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.962   Installing the file.
2015-04-16 12:56:04.976   Successfully installed the file.
2015-04-16 12:56:04.978   -- File entry --
2015-04-16 12:56:04.980   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.resources\.projects\Minecraft\.location
2015-04-16 12:56:04.982   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:04.984   Installing the file.
2015-04-16 12:56:04.985   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse
2015-04-16 12:56:04.987   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata
2015-04-16 12:56:04.989   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins
2015-04-16 12:56:04.991   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.resources
2015-04-16 12:56:04.994   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.resources\.projects
2015-04-16 12:56:04.996   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.resources\.projects\Minecraft
2015-04-16 12:56:05.006   Successfully installed the file.
2015-04-16 12:56:05.009   -- File entry --
2015-04-16 12:56:05.011   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.core.resources.prefs
2015-04-16 12:56:05.013   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.015   Installing the file.
2015-04-16 12:56:05.017   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime
2015-04-16 12:56:05.019   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings
2015-04-16 12:56:05.031   Successfully installed the file.
2015-04-16 12:56:05.033   -- File entry --
2015-04-16 12:56:05.036   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.debug.ui.prefs
2015-04-16 12:56:05.038   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.039   Installing the file.
2015-04-16 12:56:05.052   Successfully installed the file.
2015-04-16 12:56:05.055   -- File entry --
2015-04-16 12:56:05.057   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.epp.usagedata.gathering.prefs
2015-04-16 12:56:05.060   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.061   Installing the file.
2015-04-16 12:56:05.075   Successfully installed the file.
2015-04-16 12:56:05.077   -- File entry --
2015-04-16 12:56:05.079   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.jdt.core.prefs
2015-04-16 12:56:05.081   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.082   Installing the file.
2015-04-16 12:56:05.093   Successfully installed the file.
2015-04-16 12:56:05.095   -- File entry --
2015-04-16 12:56:05.097   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.ui.editors.prefs
2015-04-16 12:56:05.098   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.100   Installing the file.
2015-04-16 12:56:05.110   Successfully installed the file.
2015-04-16 12:56:05.112   -- File entry --
2015-04-16 12:56:05.114   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.ui.ide.prefs
2015-04-16 12:56:05.116   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.117   Installing the file.
2015-04-16 12:56:05.137   Successfully installed the file.
2015-04-16 12:56:05.139   -- File entry --
2015-04-16 12:56:05.141   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.ui.prefs
2015-04-16 12:56:05.143   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.144   Installing the file.
2015-04-16 12:56:05.162   Successfully installed the file.
2015-04-16 12:56:05.164   -- File entry --
2015-04-16 12:56:05.166   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.core\.launches\Client.launch
2015-04-16 12:56:05.168   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.169   Installing the file.
2015-04-16 12:56:05.171   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.core
2015-04-16 12:56:05.173   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.core\.launches
2015-04-16 12:56:05.185   Successfully installed the file.
2015-04-16 12:56:05.187   -- File entry --
2015-04-16 12:56:05.189   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.core\.launches\Server.launch
2015-04-16 12:56:05.191   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.193   Installing the file.
2015-04-16 12:56:05.205   Successfully installed the file.
2015-04-16 12:56:05.206   -- File entry --
2015-04-16 12:56:05.210   Dest filename: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.ui\launchConfigurationHistory.xml
2015-04-16 12:56:05.211   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.213   Installing the file.
2015-04-16 12:56:05.214   Creating directory: C:\Program Files (x86)\Project\forge_src\eclipse\.metadata\.plugins\org.eclipse.debug.ui
2015-04-16 12:56:05.226   Successfully installed the file.
2015-04-16 12:56:05.228   -- File entry --
2015-04-16 12:56:05.230   Dest filename: C:\Program Files (x86)\Project\forge_src\gradle\wrapper\gradle-wrapper.jar
2015-04-16 12:56:05.232   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.233   Installing the file.
2015-04-16 12:56:05.235   Creating directory: C:\Program Files (x86)\Project\forge_src\gradle
2015-04-16 12:56:05.237   Creating directory: C:\Program Files (x86)\Project\forge_src\gradle\wrapper
2015-04-16 12:56:05.262   Successfully installed the file.
2015-04-16 12:56:05.265   -- File entry --
2015-04-16 12:56:05.267   Dest filename: C:\Program Files (x86)\Project\forge_src\gradle\wrapper\gradle-wrapper.properties
2015-04-16 12:56:05.268   Time stamp of our file: 2015-03-27 14:49:32.000
2015-04-16 12:56:05.270   Installing the file.
2015-04-16 12:56:05.281   Successfully installed the file.
2015-04-16 12:56:05.283   -- File entry --
2015-04-16 12:56:05.285   Dest filename: C:\Program Files (x86)\Project\forge_src\src\main\java\com\example\examplemod\ExampleMod.java
2015-04-16 12:56:05.287   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:05.288   Installing the file.
2015-04-16 12:56:05.290   Creating directory: C:\Program Files (x86)\Project\forge_src\src
2015-04-16 12:56:05.292   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main
2015-04-16 12:56:05.294   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main\java
2015-04-16 12:56:05.296   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main\java\com
2015-04-16 12:56:05.298   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main\java\com\example
2015-04-16 12:56:05.300   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main\java\com\example\examplemod
2015-04-16 12:56:05.311   Successfully installed the file.
2015-04-16 12:56:05.315   -- File entry --
2015-04-16 12:56:05.317   Dest filename: C:\Program Files (x86)\Project\forge_src\src\main\resources\mcmod.info
2015-04-16 12:56:05.319   Time stamp of our file: 2015-03-27 14:49:34.000
2015-04-16 12:56:05.320   Installing the file.
2015-04-16 12:56:05.322   Creating directory: C:\Program Files (x86)\Project\forge_src\src\main\resources
2015-04-16 12:56:05.334   Successfully installed the file.
2015-04-16 12:56:05.335   -- File entry --
2015-04-16 12:56:05.337   Dest filename: C:\Program Files (x86)\Project\installers\gradle.bat
2015-04-16 12:56:05.338   Time stamp of our file: 2015-04-15 00:53:28.000
2015-04-16 12:56:05.339   Installing the file.
2015-04-16 12:56:05.341   Creating directory: C:\Program Files (x86)\Project\installers
2015-04-16 12:56:05.350   Successfully installed the file.
2015-04-16 12:56:05.351   -- File entry --
2015-04-16 12:56:05.353   Dest filename: C:\Program Files (x86)\Project\installers\gradle.exe
2015-04-16 12:56:05.354   Time stamp of our file: 2015-04-15 17:04:28.000
2015-04-16 12:56:05.356   Installing the file.
2015-04-16 12:56:05.375   Successfully installed the file.
2015-04-16 12:56:05.376   -- File entry --
2015-04-16 12:56:05.378   Dest filename: C:\Program Files (x86)\Project\installers\Inno Development.iss
2015-04-16 12:56:05.379   Time stamp of our file: 2015-04-16 12:55:44.000
2015-04-16 12:56:05.380   Installing the file.
2015-04-16 12:56:05.390   Successfully installed the file.
2015-04-16 12:56:05.424   Installation process succeeded.
2015-04-16 12:56:05.428   -- Run entry --
2015-04-16 12:56:05.431   Run as: Current user
2015-04-16 12:56:05.432   Type: Exec
2015-04-16 12:56:05.433   Filename: E:\Project\installers\gradle.bat
2015-04-16 12:56:05.613   Process exit code: 1
2015-04-16 12:56:05.616   Need to restart Windows? No
2015-04-16 12:56:07.229   Deinitializing Setup.
2015-04-16 12:56:07.241   Log closed.
1

1 Answers

2
votes

First problem is that you refer to a source file in the [Run] section, instead of the installed file.

Unrelated side-note: You should also not be hard-coding a path to Program Files (x86). Use a {pf}, {pf32}, or even better an {app} constants.

[Files]
Source: "E:\Project\*.*"; DestDir: "{app}"; Flags: recursesubdirs

[Run]
Filename: "{app}\installers\gradle.bat";

But if you are actually testing the installer on the same machine you build it, the installer should still find the gradle.bat in the source directory.

In such case the problem will be the with the actual batch file. We cannot help you with that, without seeing its code. General hint is to add some logging to the batch file and inspect that. You can extract the code to a separate batch file (e.g. gradle_internal.bat) and call that from gradle.bat with redirect:

gradle_internal.bat 2>&1 > %TEMP%\gradle.log