-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathinstall.iss
More file actions
82 lines (69 loc) · 3.45 KB
/
install.iss
File metadata and controls
82 lines (69 loc) · 3.45 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
#define MyAppName "iQuality"
#define MyAppVersion "0.223" ; auto-generated
#define MyAppPublisher "Itay Brandes"
#define MyAppURL "http://iQuality.iTayb.net"
#define MyAppExeName "iQuality.exe"
#define BuildArch "win32" ; auto-generated
[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={{218B1FC3-5CE1-45B3-82C1-5C7390EFE744}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={pf}\{#MyAppName}
DefaultGroupName={#MyAppName}
LicenseFile=C:\Scripts\iQuality\agreement.txt
InfoAfterFile=C:\Scripts\iQuality\README.md
OutputDir=C:\scripts\iQuality\dist
OutputBaseFilename={#MyAppName}-{#MyAppVersion}-installer
UninstallDisplayIcon={app}\{#MyAppExeName}
Compression=lzma
SolidCompression=yes
[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "hebrew"; MessagesFile: "compiler:Languages\Hebrew.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"
Name: "quicklaunchicon"; Description: "{cm:CreateQuickLaunchIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked; OnlyBelowVersion: 0,6.1
[Dirs]
Name: "{app}"; Permissions: users-modify;
[Files]
Source: "C:\Scripts\iQuality\dist\iQuality-{#MyAppVersion}.{#BuildArch}\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs
Source: "C:\Scripts\iQuality\agreement.txt"; DestDir: "{app}";
Source: "C:\Scripts\iQuality\ChangeLog.txt"; DestDir: "{app}";
Source: "C:\Scripts\iQuality\README.md"; DestDir: "{app}"; DestName: README.txt;
[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{group}\ID3 Tagger"; Filename: "{app}\{#MyAppExeName}"; Parameters: "/id3"; IconFilename: "{app}\pics\id3edit.ico"
Name: "{group}\Uninstall"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon
Name: "{userappdata}\Microsoft\Internet Explorer\Quick Launch\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: quicklaunchicon
[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall runascurrentuser skipifsilent
; Up to version v0.191, the program folder structer was kinda different.
; If we already have an older version installed, we need to move and remove
; some files to make it work with the new struct.
[Code]
function IsOldVersion: Boolean;
begin
Result := FileExists(ExpandConstant('{app}\PyQt4.QtCore.pyd'));
end;
function PrepareToInstall(var NeedsRestart: Boolean): String;
begin
NeedsRestart := False;
if IsOldVersion then begin
if not DirExists(ExpandConstant('{userappdata}\iQuality')) then begin
CreateDir(ExpandConstant('{userappdata}\iQuality'))
end;
FileCopy(ExpandConstant('{app}\config.ini'),ExpandConstant('{userappdata}\iQuality\config.ini'), True);
FileCopy(ExpandConstant('{app}\debug.log'),ExpandConstant('{userappdata}\iQuality\debug.log'), True);
FileCopy(ExpandConstant('{app}\debug.calcScore.log'),ExpandConstant('{userappdata}\iQuality\debug.calcScore.log'), True);
DelTree(ExpandConstant('{app}'), False, True, True);
end;
end;