-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathinstaller.iss
More file actions
77 lines (67 loc) · 2.58 KB
/
Copy pathinstaller.iss
File metadata and controls
77 lines (67 loc) · 2.58 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
; Inno Setup script for FastSMRW.
; Invoked by build.bat / CI with the version and the dist folder on the command
; line, e.g.:
; ISCC.exe /DMyAppVersion=0.1.0 /DSourceDir=dist /DOutputDir=. installer.iss
; Produces FastSMRWInstaller.exe. The installer writes an "installed.txt" marker
; next to the exe; the in-app updater keys off that marker to update an installed
; copy via this setup (silently) instead of the portable zip.
#define MyAppName "FastSMRW"
#define MyAppPublisher "Mew"
#define MyAppURL "https://masonasons.me"
#define MyAppExeName "FastSMRW.exe"
#ifndef MyAppVersion
#define MyAppVersion "0.0.0"
#endif
#ifndef SourceDir
#define SourceDir "dist"
#endif
#ifndef OutputDir
#define OutputDir "."
#endif
[Setup]
AppId={{B7E4F2A1-9C3D-4E6F-A1B2-3C4D5E6F7A8B}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={autopf}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
OutputBaseFilename=FastSMRWInstaller
OutputDir={#OutputDir}
Compression=lzma2/max
SolidCompression=yes
WizardStyle=modern
; Admin by default (Program Files), but the user may choose a per-user install.
PrivilegesRequired=admin
PrivilegesRequiredOverridesAllowed=dialog
ArchitecturesAllowed=x64compatible
ArchitecturesInstallIn64BitMode=x64compatible
UninstallDisplayIcon={app}\{#MyAppExeName}
UninstallDisplayName={#MyAppName}
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
[Files]
; Install the whole run folder (exe, speech DLLs, soundpacks, keymaps, docs).
Source: "{#SourceDir}\*"; DestDir: "{app}"; Flags: recursesubdirs createallsubdirs ignoreversion
[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent
[UninstallDelete]
Type: files; Name: "{app}\installed.txt"
[Code]
// Drop a marker so the running app knows it was installed (vs. portable). A
// portable zip never contains this file.
procedure CurStepChanged(CurStep: TSetupStep);
begin
if CurStep = ssPostInstall then
SaveStringToFile(ExpandConstant('{app}\installed.txt'), 'Installed via setup', False);
end;