1. 先展示几张效果图:
2. 下载免费的Inno Setup程序
https://jrsoftware.org/isdl.php
3. Inno Setup程序入门
Inno Setup的安装目录下面有很多demo,供我们参考
4. 我的Inno Setup打包实例
; -- Example1.iss --
; Demonstrates copying 3 files and creating an icon.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES!
[Setup]
AppName={cm:MyAppName}
AppId=GetVehicleInfoApp
AppVersion={cm:MyAppVerName,1.0}
WizardStyle=modern
DefaultDirName={autopf}\{cm:MyAppName}
DefaultGroupName={cm:MyAppName}
DisableProgramGroupPage=yes
UninstallDisplayIcon={app}\GetVehInfoClientApp.exe
VersionInfoDescription=GetVehInfoClientApp Setup
VersionInfoProductName=GetVehInfoClientApp
;Compression=lzma2
;SolidCompression=yes
OutputDir=userdocs:Inno Setup Examples Output
; Uncomment the following line to disable the "Select Setup Language"
; dialog and have it rely solely on auto-detection.
;ShowLanguageDialog=no
[Languages]
Name: ch; MessagesFile: "compiler:Chinese.isl"
[Messages]
ch.BeveledLabel=Chinese
[CustomMessages]
ch.MyDescription=My description
ch.MyAppName=GetVehicleInfoApp
ch.MyAppVerName=GetVehicleInfoApp %1
[Dirs]
Name: "{app}\Log"
Name: "{app}\x64"
Name: "{app}\x86"
[Files]
Source: "x64\SQLite.Interop.dll"; DestDir: "{app}\x64"
Source: "x86\SQLite.Interop.dll"; DestDir: "{app}\x86"
Source: "AutoMapper.dll"; DestDir: "{app}"
Source: "AutoMapper.xml"; DestDir: "{app}"
Source: "EntityFramework.dll"; DestDir: "{app}"
Source: "EntityFramework.SqlServer.dll"; DestDir: "{app}"
Source: "EntityFramework.SqlServer.xml"; DestDir: "{app}"
Source: "EntityFramework.xml"; DestDir: "{app}"
Source: "GetVehInfoClientApp.exe"; DestDir: "{app}"
Source: "GetVehInfoClientApp.exe.config"; DestDir: "{app}"
Source: "GetVehInfoClientApp.pdb"; DestDir: "{app}"
Source: "huayan.ClassLibrary.dll"; DestDir: "{app}"
Source: "HYUILibrary.dll"; DestDir: "{app}"
Source: "Newtonsoft.Json.dll"; DestDir: "{app}"
Source: "Newtonsoft.Json.xml"; DestDir: "{app}"
Source: "Pcomm.dll"; DestDir: "{app}"
Source: "Promm.db3"; DestDir: "{app}"
Source: "System.Data.SQLite.dll"; DestDir: "{app}"
Source: "System.Data.SQLite.dll.config"; DestDir: "{app}"
Source: "System.Data.SQLite.EF6.dll"; DestDir: "{app}"
Source: "System.Data.SQLite.Linq.dll"; DestDir: "{app}"
Source: "System.Data.SQLite.xml"; DestDir: "{app}"
Source: "环保视频下载协议.pdf"; DestDir: "{app}"; Flags: isreadme
[Icons]
Name: "{group}\{cm:MyAppName}"; Filename: "{app}\GetVehInfoClientApp.exe"
Name: "{group}\{cm:UninstallProgram,{cm:MyAppName}}"; Filename: "{uninstallexe}"
Name: "{autoprograms}\{cm:MyAppName}"; Filename: "{app}\GetVehInfoClientApp.exe"
Name: "{autodesktop}\{cm:MyAppName}"; Filename: "{app}\GetVehInfoClientApp.exe"
[Tasks]
; The following task doesn't do anything and is only meant to show [CustomMessages] usage
Name: mytask; Description: "{cm:MyDescription}"