-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathinstaller.iss
More file actions
96 lines (85 loc) · 3.68 KB
/
installer.iss
File metadata and controls
96 lines (85 loc) · 3.68 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
; ============================================================================
; Protector ISAPI Manager v4.0 - Inno Setup Script
; Protector Sistemas
;
; Gera instalador profissional para Windows (.exe)
; Requer: Inno Setup 6.x (https://jrsoftware.org/isinfo.php)
;
; Para gerar o instalador:
; 1. Faca o build com PyInstaller (python build_release.py)
; 2. Abra este arquivo no Inno Setup Compiler
; 3. Clique em Compile (Ctrl+F9)
; OU use a linha de comando:
; iscc installer.iss
; ============================================================================
#define MyAppName "Protector ISAPI Manager"
#define MyAppVersion "4.2.1"
#define MyAppPublisher "Protector Sistemas"
#define MyAppURL "https://github.com/ProtectorAnalytics/protector-isapi-manager"
#define MyAppExeName "Protector_ISAPI_Manager.exe"
#define MyAppIcon "assets\icon.ico"
[Setup]
AppId={{B8F2A4D1-7E3C-4A5B-9D6F-1C2E8A9B3D4F}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppVerName={#MyAppName} v{#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}/issues
AppUpdatesURL={#MyAppURL}/releases
DefaultDirName={autopf}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
Compression=lzma2/ultra64
SolidCompression=yes
WizardStyle=modern
PrivilegesRequired=admin
PrivilegesRequiredOverridesAllowed=dialog
OutputDir=dist\installer
OutputBaseFilename=Protector_ISAPI_Manager_v{#MyAppVersion}_Setup
SetupIconFile={#MyAppIcon}
UninstallDisplayIcon={app}\{#MyAppExeName}
UninstallDisplayName={#MyAppName}
VersionInfoVersion={#MyAppVersion}.0
VersionInfoCompany={#MyAppPublisher}
VersionInfoDescription={#MyAppName} Installer
VersionInfoProductName={#MyAppName}
CloseApplications=yes
CloseApplicationsFilter=*.exe
RestartApplications=yes
ArchitecturesInstallIn64BitMode=x64compatible
[Languages]
Name: "brazilianportuguese"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
Name: "english"; MessagesFile: "compiler:Default.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"
Name: "startup"; Description: "Iniciar com o Windows"; GroupDescription: "Opcoes adicionais:"
[Files]
Source: "dist\Protector_ISAPI_Manager.exe"; DestDir: "{app}"; Flags: ignoreversion
Source: "dados.json"; DestDir: "{app}"; Flags: ignoreversion skipifsourcedoesntexist onlyifdoesntexist
Source: "terminais.json"; DestDir: "{app}"; Flags: ignoreversion skipifsourcedoesntexist onlyifdoesntexist
Source: "assets\*"; DestDir: "{app}\assets"; Flags: ignoreversion recursesubdirs createallsubdirs skipifsourcedoesntexist
[Dirs]
Name: "{app}\Backups"; Permissions: users-modify
Name: "{app}\Reports"; Permissions: users-modify
Name: "{app}\Events"; Permissions: users-modify
Name: "{app}\Logs"; Permissions: users-modify
Name: "{app}\Sessions"; Permissions: users-modify
[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\Desinstalar {#MyAppName}"; Filename: "{uninstallexe}"
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
[Registry]
Root: HKCU; Subkey: "Software\Microsoft\Windows\CurrentVersion\Run"; ValueType: string; ValueName: "{#MyAppName}"; ValueData: """{app}\{#MyAppExeName}"""; Flags: uninsdeletevalue; Tasks: startup
[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent
[UninstallRun]
Filename: "taskkill"; Parameters: "/f /im {#MyAppExeName}"; Flags: runhidden; RunOnceId: "KillApp"
[Code]
function InitializeSetup(): Boolean;
var
ResultCode: Integer;
begin
Result := True;
Exec('taskkill', '/f /im Protector_ISAPI_Manager.exe', '', SW_HIDE, ewWaitUntilTerminated, ResultCode);
end;