Debian Codegraph @

builds/install/arch-specific/win32/test_installer/Innosetup-command-line-reference.md

raw
1 # Setup Command Line Parameters
2
3 (Taken from InnoSetup Help v. 6.1.2 Deember 2020)
4
5 The Setup program accepts optional command line parameters. These can be useful to system administrators, and to other programs calling the Setup program.
6
7
8 **/HELP, /?**
9
10 Shows a summary of this information. Ignored if the UseSetupLdr [Setup] section directive was set to no.
11
12
13 **/SP-**
14
15 Disables the This will install... Do you wish to continue? prompt at the beginning of Setup. Of course, this will have no effect if the DisableStartupPrompt [Setup] section directive was set to yes.
16
17
18 **/SILENT, /VERYSILENT**
19
20 Instructs Setup to be silent or very silent. When Setup is silent the wizard and the background window are not displayed but the installation progress window is. When a setup is very silent this installation progress window is not displayed. Everything else is normal so for example error messages during installation are displayed and the startup prompt is (if you haven't disabled it with DisableStartupPrompt or the '/SP-' command line option explained above).
21
22 If a restart is necessary and the '/NORESTART' command isn't used (see below) and Setup is silent, it will display a Reboot now? message box. If it's very silent it will reboot without asking.
23
24
25 **/SUPPRESSMSGBOXES**
26
27 Instructs Setup to suppress message boxes. Only has an effect when combined with '/SILENT' or '/VERYSILENT'.
28
29 The default response in situations where there's a choice is:
30
31 - Yes in a 'Keep newer file?' situation.
32 - No in a 'File exists, confirm overwrite.' situation.
33 - Abort in Abort/Retry situations.
34 - Cancel in Retry/Cancel situations.
35 - Yes (=continue) in a DiskSpaceWarning/DirExists/DirDoesntExist/NoUninstallWarning/ExitSetupMessage/ConfirmUninstall situation.
36 - Yes (=restart) in a FinishedRestartMessage/UninstalledAndNeedsRestart situation.
37 - The recommended choice in a PrivilegesRequiredOverridesAllowed=dialog situation.
38
39 5 message boxes are not suppressible:
40
41 - The About Setup message box.
42 - The Exit Setup? message box.
43 - The FileNotInDir2 message box displayed when Setup requires a new disk to be inserted and the disk was not found.
44 - Any (error) message box displayed before Setup (or Uninstall) could read the command line parameters.
45 - Any task dialog or message box displayed by [Code] support functions TaskDialogMsgBox and MsgBox.
46
47 **/ALLUSERS**
48
49 Instructs Setup to install in administrative install mode. Only has an effect when the [Setup] section directive PrivilegesRequiredOverridesAllowed allows the commandline override.
50
51 **/CURRENTUSER**
52
53 Instructs Setup to install in non administrative install mode. Only has an effect when the [Setup] section directive PrivilegesRequiredOverridesAllowed allows the commandline override.
54
55 **/LOG**
56
57 Causes Setup to create a log file in the user's TEMP directory detailing file installation and [Run] actions taken during the installation process. This can be a helpful debugging aid. For example, if you suspect a file isn't being replaced when you believe it should be (or vice versa), the log file will tell you if the file was really skipped, and why.
58
59 The log file is created with a unique name based on the current date. (It will not overwrite or append to existing files.)
60
61 The information contained in the log file is technical in nature and therefore not intended to be understandable by end users. Nor is it designed to be machine-parsable; the format of the file is subject to change without notice.
62
63 **/LOG="filename"**
64
65 Same as /LOG, except it allows you to specify a fixed path/filename to use for the log file. If a file with the specified name already exists it will be overwritten. If the file cannot be created, Setup will abort with an error message.
66
67 **/NOCANCEL**
68
69 Prevents the user from cancelling during the installation process, by disabling the Cancel button and ignoring clicks on the close button. Useful along with '/SILENT' or '/VERYSILENT'.
70
71 **/NORESTART**
72
73 Prevents Setup from restarting the system following a successful installation, or after a Preparing to Install failure that requests a restart. Typically used along with /SILENT or /VERYSILENT.
74
75 **/RESTARTEXITCODE=exit code**
76
77 Specifies a custom exit code that Setup is to return when the system needs to be restarted following a successful installation. (By default, 0 is returned in this case.) Typically used along with /NORESTART. See also: Setup Exit Codes
78
79 **/CLOSEAPPLICATIONS**
80
81 Instructs Setup to close applications using files that need to be updated by Setup if possible.
82
83 **/NOCLOSEAPPLICATIONS**
84
85 Prevents Setup from closing applications using files that need to be updated by Setup. If /CLOSEAPPLICATIONS was also used, this command line parameter is ignored.
86
87 **/FORCECLOSEAPPLICATIONS**
88
89 Instructs Setup to force close when closing applications.
90
91 **/NOFORCECLOSEAPPLICATIONS**
92
93 Prevents Setup from force closing when closing applications. If /FORCECLOSEAPPLICATIONS was also used, this command line parameter is ignored.
94
95 **/LOGCLOSEAPPLICATIONS**
96
97 Instructs Setup to create extra logging when closing applications for debugging purposes.
98
99 **/RESTARTAPPLICATIONS**
100
101 Instructs Setup to restart applications if possible.
102
103 **/NORESTARTAPPLICATIONS**
104
105 Prevents Setup from restarting applications. If /RESTARTAPPLICATIONS was also used, this command line parameter is ignored.
106
107 **/LOADINF="filename"**
108
109 Instructs Setup to load the settings from the specified file after having checked the command line. This file can be prepared using the '/SAVEINF=' command as explained below.
110
111 Don't forget to use quotes if the filename contains spaces.
112
113 **/SAVEINF="filename"**
114
115 Instructs Setup to save installation settings to the specified file.
116
117 Don't forget to use quotes if the filename contains spaces.
118
119 **/LANG=language**
120
121 Specifies the language to use. language specifies the internal name of the language as specified in a [Languages] section entry.
122
123 When a valid /LANG parameter is used, the Select Language dialog will be suppressed.
124
125 **/DIR="x:\dirname"**
126
127 Overrides the default directory name displayed on the Select Destination Location wizard page. A fully qualified pathname must be specified. May include an "expand:" prefix which instructs Setup to expand any constants in the name. For example: '/DIR=expand:{autopf}\My Program'.
128
129 **/GROUP="folder name"**
130
131 Overrides the default folder name displayed on the Select Start Menu Folder wizard page. May include an "expand:" prefix, see '/DIR='. If the [Setup] section directive DisableProgramGroupPage was set to yes, this command line parameter is ignored.
132
133 **/NOICONS**
134
135 Instructs Setup to initially check the Don't create a Start Menu folder check box on the Select Start Menu Folder wizard page.
136
137 **/TYPE=type name**
138
139 Overrides the default setup type.
140
141 If the specified type exists and isn't a custom type, then any /COMPONENTS parameter will be ignored.
142
143 **/COMPONENTS="comma separated list of component names"**
144
145 Overrides the default component settings. Using this command line parameter causes Setup to automatically select a custom type. If no custom type is defined, this parameter is ignored.
146
147 Only the specified components will be selected; the rest will be deselected.
148
149 If a component name is prefixed with a "*" character, any child components will be selected as well (except for those that include the dontinheritcheck flag). If a component name is prefixed with a "!" character, the component will be deselected.
150
151 This parameter does not change the state of components that include the fixed flag.
152
153 Example:
154
155 Deselect all components, then select the "help" and "plugins" components:
156
157 ```
158 /COMPONENTS="help,plugins"
159 ```
160
161 Example:
162
163 Deselect all components, then select a parent component and all of its children with the exception of one:
164
165 ```
166 /COMPONENTS="*parent,!parent\child" /TASKS="comma separated list of task names"
167 ```
168
169 Specifies a list of tasks that should be initially selected.
170
171 Only the specified tasks will be selected; the rest will be deselected. Use the /MERGETASKS parameter instead if you want to keep the default set of tasks and only select/deselect some of them.
172
173 If a task name is prefixed with a "*" character, any child tasks will be selected as well (except for those that include the dontinheritcheck flag). If a task name is prefixed with a "!" character, the task will be deselected.
174
175 Example:
176
177 Deselect all tasks, then select the "desktopicon" and "fileassoc" tasks:
178
179 ```
180 /TASKS="desktopicon,fileassoc"
181 ```
182
183 Example:
184
185 Deselect all tasks, then select a parent task and all of its children with the exception of one:
186
187 ```
188 /TASKS="*parent,!parent\child" /MERGETASKS="comma separated list of task names"
189 ```
190
191 Like the /TASKS parameter, except the specified tasks will be merged with the set of tasks that would have otherwise been selected by default.
192
193 If UsePreviousTasks is set to yes, the specified tasks will be selected/deselected after any previous tasks are restored.
194
195 Example:
196
197 Keep the default set of selected tasks, but additionally select the "desktopicon" and "fileassoc" tasks:
198
199 ```
200 /MERGETASKS="desktopicon,fileassoc"
201 ```
202
203 Example:
204
205 Keep the default set of selected tasks, but deselect the "desktopicon" task:
206
207 ```
208 /MERGETASKS="!desktopicon" /PASSWORD=password
209 ```
210
211 Specifies the password to use. If the [Setup] section directive Password was not set, this command line parameter is ignored.
212
213 When an invalid password is specified, this command line parameter is also ignored.