-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathinstaller.iss
More file actions
90 lines (80 loc) · 3.54 KB
/
installer.iss
File metadata and controls
90 lines (80 loc) · 3.54 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
; =============================================================================
; AnimeFlow - Inno Setup 安装脚本
; =============================================================================
; 1. 构建 Release:
; flutter build windows --release
; 2. 用 Inno Setup Compiler 打开本文件并编译
;
; 本地发布前:把下一行占位符 "version" 改成与 pubspec.yaml 一致的 x.y.z。
; CI(build.yml)会在编译安装包前自动将 "version" 替换为 pubspec 的 x.y.z。
; 覆盖升级:勿修改 MyAppGuid / AppId;仅提高版本号。检测到旧版时会默认沿用原安装目录并覆盖文件。
; =============================================================================
#define MyAppName "AnimeFlow"
#define MyAppVersion "version"
#define MyAppExeName "AnimeFlow.exe"
#define MyAppPublisher "AnimeFlow"
#define MyAppURL "https://github.com/openAnimeFlow/AnimeFlow"
; Flutter Windows x64 构建输出目录(相对本 .iss 所在目录,即项目根目录)
#define BuildSourceDir "build\windows\x64\runner\Release"
#define OutputBaseName "AnimeFlow-windows-setup-" + MyAppVersion
#define OutputDir "."
; 固定 AppId(GUID 本体,不含花括号)以便覆盖安装与干净卸载;勿随意更改
#define MyAppGuid "B8E4F2A1-3C7D-5E9F-8A1B-2D4F6E8C0A9B"
#define AppIdEscaped "{{" + MyAppGuid + "}}"
[Setup]
AppId={#AppIdEscaped}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={autopf64}\{#MyAppName}
DefaultGroupName={#MyAppName}
AllowNoIcons=yes
OutputDir={#OutputDir}
OutputBaseFilename={#OutputBaseName}
SetupIconFile=windows\runner\resources\app_icon.ico
UninstallDisplayIcon={app}\{#MyAppExeName}
UninstallDisplayName={#MyAppName}
Compression=lzma2/ultra64
SolidCompression=yes
WizardStyle=modern
PrivilegesRequired=admin
ArchitecturesAllowed=x64compatible
ArchitecturesInstallIn64BitMode=x64compatible
; 覆盖安装 / 升级:与旧版共用 AppId 时沿用上次安装目录与开始菜单位置
UsePreviousAppDir=yes
UsePreviousGroup=yes
UsePreviousTasks=yes
UsePreviousSetupType=yes
; 已检测到旧版时自动跳过对应向导页,减少误选路径
DisableDirPage=auto
DisableProgramGroupPage=auto
DisableWelcomePage=no
CloseApplications=yes
; 互斥体勿含版本号,保证任意新版安装包与旧版不能同时跑两个安装向导
SetupMutex=AnimeFlowSetup_{#MyAppGuid}
RestartApplications=no
ShowLanguageDialog=yes
MinVersion=10.0
UsedUserAreasWarning=no
VersionInfoVersion={#MyAppVersion}.0
VersionInfoCompany={#MyAppPublisher}
VersionInfoDescription={#MyAppName}
VersionInfoProductName={#MyAppName}
VersionInfoProductVersion={#MyAppVersion}
[Languages]
Name: "chinesesimp"; MessagesFile: "compiler:Languages\Chinese.isl"
Name: "english"; MessagesFile: "compiler:Default.isl"
[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: unchecked
[Files]
Source: "{#BuildSourceDir}\*"; DestDir: "{app}"; Flags: ignoreversion recursesubdirs createallsubdirs
[Icons]
Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; WorkingDir: "{app}"
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
Name: "{autodesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; WorkingDir: "{app}"; Tasks: desktopicon
[Run]
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#MyAppName}}"; Flags: nowait postinstall skipifsilent