menu Chancel's Blog
rss_feed lightbulb_outline

Inno打包配置文件示例

类型:Software
创建时间:2021-06-15 17:30:22
更新时间:2021-06-15 17:30:22
类型:Software
更新时间:2021-06-15 17:30:22

Inno Setup是Jordan Russell和Martijn Laan的Windows程序的免费安装程序

Inno Setup is a free installer for Windows programs by Jordan Russell and Martijn Laan. First introduced in 1997, Inno Setup today rivals and even surpasses many commercial installers in feature set and stability.

下面是仅供参考的配置文件,请注意时效性,随着Inno Setup版本更迭配置文件中的部分信息可能失效

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define MyAppName "HelloWorld"
#define MyAppVersion "0.9"
#define MyAppPublisher "chancel's company"
#define MyAppURL "https://www.chancel.ltd/"
#define MyAppExeName "helloworld.exe"

[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={{8435E930-A931-4967-8844-46X547X3BD8D}
AppName={#MyAppName}
AppVersion={#MyAppVersion}
;AppVerName={#MyAppName} {#MyAppVersion}
AppPublisher={#MyAppPublisher}
AppPublisherURL={#MyAppURL}
AppSupportURL={#MyAppURL}
AppUpdatesURL={#MyAppURL}
DefaultDirName={userappdata}\{#MyAppName}
DisableProgramGroupPage=yes
DisableDirPage=no
;安装包的输出目录
OutputDir=D:\inno\output\{#MyAppName}
OutputBaseFilename={#MyAppName}_v{#MyAppVersion}
; 安装包的图标
;SetupIconFile=D:\inno\input\ico\_logo.ico
Compression=lzma
SolidCompression=yes
;此处 限制Windows最低版本为Windows 7
MinVersion=0.0,6.0


[Languages]
;安装语言许选择
Name: "chinesesimplified"; MessagesFile: "compiler:Languages\ChineseSimplified.isl"

[Tasks]
;创建桌面快捷键
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; Flags: checkablealone

[Files]
;打包源文件与要安装的目标文件夹,DestDir需要参考官网文档,有多个枚举可选择
Source: "D:\inno\input\Release\*"; DestDir: "{app}\"; Flags: recursesubdirs ignoreversion
; NOTE: Don't use "Flags: ignoreversion" on any shared system files

[Icons]
;图标选择
Name: "{commonprograms}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"
Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon

[Run]
;程序安装成功后入口执行程序
Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent

[[replyMessage== null?"发表评论":"@" + replyMessage.m_author]]

account_circle
email
web_asset
textsms

评论列表([[messageList.data.items.length]])

[[messageItem.m_author]] [[messageItem.m_author]]
[[messageItem.create_time]]
[[messageItem.m_environ.browser]] [[messageItem.m_environ.os]] [[messageItem.m_environ.device]]
[[subMessage.m_author]] [[subMessage.m_author]] @ [[subMessage.parent_message.m_author]] [[subMessage.parent_message.m_author]]
[[subMessage.create_time]]
[[subMessage.m_environ.browser]] [[subMessage.m_environ.os]] [[subMessage.m_environ.device]]