1. I have a Python program that I want to run
2 on a computer that does not have a python environment installed. I will package the python program using Pyinstaller as a .exe application
3, and then package this application into an installation package
4 using Inno Setup. Install this installation package on the computer and set it to boot.
requirements:
1. This computer does not have python environment installed
2. This program is set to boot
3. Windows cannot pop up at startup and should be hidden, just like mysql and tomcat services
this is the content of my Inno Setup.iss file:
; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId= {{B5DEB7D6-1A25-408C-90C1-AF45F08023E2}
AppName= {- sharpMyAppName}
AppVersion= {- sharpMyAppVersion}
; AppVerName= {- sharpMyAppName} {- sharpMyAppVersion}
AppPublisher= {- sharpMyAppPublisher}
AppPublisherURL= {- sharpMyAppURL}
AppSupportURL= {- sharpMyAppURL}
AppUpdatesURL= {- AppUpdatesURL=} > AppUpdatesURL= {- AppUpdatesURL=} > sharpMyAppURL {- sharpMyAppURL} > br < > < >
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
[Files]
Source: "C:UsersAdministratorDesktopGJGSGJGS_APP.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "C:UsersAdministratorDesktopGJGSGJGS_APP.exe"; DestDir: "{app}"; Flags: ignoreversion
; NOTE: Don"t use "Flags: ignoreversion" on any shared system files
[Icons]
Name: "{commonprograms} {- sharpMyAppName}"; Filename: "{app} {- sharpMyAppExeName}"
Name: "{commondesktop} {- sharpMyAppName}"; Filename: "{app} {- sharpMyAppExeName}"; Tasks: desktopicon
[Run]
Filename: "{app} {- sharpMyAppExeName}"; Description: "{cm:LaunchProgram, {- sharpStringChange (MyAppName,"&","& &")}}"; Flags: nowait postinstall skipifsilent
Filename: "{app} {- sharpMyAppExeName}"; Parameters: "- install"
Filename: "net.exe"; Parameters: "start MyAppExeName"; Flags:runhidden
[UninstallRun]
Filename: "{app} {- sharpMyAppExeName}"; Parameters: "--uninstall"