Reputation: 3576
In my installer I have a couple of optional downloadable components which are deselected by default. Is there any way to mark them as selected when using starting the installer in quiet mode without using a response/varfile?
For example I have the following lines in the varfile:
sys.component.component1$Boolean=false
sys.component.component2$Boolean=true
sys.component.component3$Boolean=false
These tell the installer to only install the second optional component.
Is there any way to automatically map these to a variable name, or have them in any way settable without a varfile, straight from the command line?
Something along the lines of ./setup.sh -q -dir /path/to/install -Vcomp1notselect -Vcomp3notselect
In the installer I do a context.getInstallationComponentById("component1").isSelected()
check to see if I need to perform some custom actions with that component.
Upvotes: 1
Views: 265
Reputation: 48005
-Vsys.component.component1$Boolean=false
would work on the command line. Alternatively, you can use
-Vcomp1deselect=true
and add a "Run script" action with script like:
if ("true".equalsIgnoreCase((String)context.getVariable("comp1deselect"))) {
context.getInstallationComponentById("component1").setSelected(false);
}
Upvotes: 1