InstallBuilder actions are organized in what are called action lists, which are executed at specific points of the installation process. It is important to understand how and when each action must be performed, what differences exist between action lists inside components and within the primary installer, how the installer will behave when you run it in different installation modes (GUI, text, or unattended) and what happens when you generate rpm or deb packages.
You can place your action lists in the main installer project or in one of its components. Action lists include your actions of choice and are executed at a specific point of the installation process as outlined below.
BitRock InstallBuilder Action Lists (in order of execution)
BUILDING THE INSTALLER
Executes before generating the installer file. These actions usually include setting environment variables or performing some kind of processing on the files that will go into the installer before they are packed into it. For multi-platform CDROM installers, the preBuildActionList is executed once at the beginning of the CDROM build, and then again for every one of the specific platform installers.
Executes after generating the installer file. These actions are usually useful to reverse any changes made to the files during the preBuildActionList or to perform additional actions on the generated installer, such as signing it by invoking an external tool. For multi-platform CDROM installers, the postBuildActionList is executed once for every one of the specific platform installers and then it is executed one final time for the whole CDROM build.
Executes before help information is displayed.
Executes when the installer has started, just before the parsing of the command line options.
Executes before the first page of the installer is displayed, right after the parsing of the command line options takes place. It is commonly used for setting user-defined installer variables that will be used later on or for detecting a Java (tm) Runtime Environment.
Executes after the component page is displayed to check that the selected components are a valid combination.
For each parameterPage, you can specify 3 different action lists: validationActionList, preShowPageActionList and postShowPageActionList. Note that those actions are not executed if the installer is executed in unattended mode.
Executes once the user has specified a value in the user interface page associated with the parameter and has pressed the 'Next' button (or 'Enter' in a text-based interface). The actions can be used to check that the value is valid (for example, that it specifies a path to a valid Perl interpreter). If any of the actions result in an error, an error message will be displayed to the user and the user will be prompted to enter a valid value.
Executes before the corresponding parameter page is displayed. This can be useful for changing the value of the parameter before it is displayed.
Executes after the corresponding parameter page has been displayed. This can be useful for performing actions or setting environment variables based on the value of the parameter.
Executes right before the file copying step starts. It is commonly used to execute actions that depend on user input.
- Folder actionList
Executes just after files defined in the particular folder are installed, the next folder files are copied and its actionList executed, etc.
Executes after the installation process has taken place but before the uninstaller is created and the final page is displayed.
Executes after the uninstaller has been created but before the final page has been displayed.
Executes after the installation has completed and the final page has been displayed to the user. These actions usually include launching the program that has just been installed. For each one of the actions contained in this list, a checkbox will be displayed (or a question in text mode). If the checkbox is selected, then the action will be executed when the 'Finish' button is pressed. The text displayed can be specified in the
Executes before the uninstallation process takes place, such as unsetting user-defined installer variables or deleting files created after installation occured.
Executes after the uninstallation process takes place.
SPECIAL ACTION LISTS
Executes when the installation process is aborted.
Order of Execution of Action Lists
Each action list may be included in the main project or inside the components. Lets take an initializationActionList as an example. We have one main initializationActionList and 4 others in the components A, B, C and D. The components are declared following the order A, B, C, D (A is the first entry and D is the last one). In this case, the main initializationActionList is executed first and then each component's action lists are executed (A, B, C, D - the order of component declaration is important).
We can divide all action lists into two groups based on what is executed earlier: main project or components action lists:
- the main project action lists then components onespreBuildActionList, initializationActionList, preIstallationActionList, readyToInstallActionList, preUninstallationActionList
- components action lists then the main project onespostBuildActionList, postInstallationActionList, postUninstallationActionList
The installer executes action lists by group, which means that first all initializationActionList actions take place and then all preInstallationActionList actions are executed.
Unattended mode, RPM and DEB packages
These are special cases. There is no interaction with the user and the following action lists are not executed:
- Any parameter's validationActionList
- Any parameter's preShowPageActionList
- Any parameter's postShowPageActionList
The installationAbortedActionList will only be executed if the error was generated by any of the actions performed directly by the installer. If the error is generated during the file installation step, which is performed by the RPM / DEB package manager, the BitRock installer application will not be notified and therefore the installationAbortedActionList will not be executed.
Post a Comment