ah34
Posts: 11
Joined: Fri May 19, 2006 4:15 pm

Command line: -buildslist and /SetVersion

Hi,

I have been trying to figure out how to use Advanced Installer from the command line with Ant.

First problem was which character to use for separating builds in the -buildslist
After trial and error, I found out that this is neither the space nor the colon nor the comma but the semicolon. Please add this simple piece of information to your help file!

An example for the command line:

Code: Select all

[path]\AdvancedInstaller.com /rebuild path/project.aip -buildslist DefaultBuild;UpdateBuild;AnotherBuild
The next problem was to find out how set the version. Initially I tried to append the /SetVersion command line parameter to the /rebuild command. But it took me a while to find out that this is not possible. Why? It would be so simple.

In the process I created a Command File which worked. But it clearly was overkill to use a command file for setting just the version. Then I realized that I need to run several commands, one for setting the version, the next for rebuilding. So here is how to set the version:

Code: Select all

[path]\AdvancedInstaller.com /edit path/project.aip /SetVersion 2.0.7
It would be great if this information were added to the help file!

Converted to an Ant task this looks as follows (maybe it is of help to someone):

Code: Select all

		 <exec executable="${ADVANCED_INSTALLER_COM}" failonerror="true">
		    <arg value="/edit" />
		  	<arg file="src/AdvancedInstaller/MyProject.aip"/>
		 	<arg value="/SetVersion"/>
		 	<arg value="${version}" />
		 </exec>
		
	    <exec executable="${ADVANCED_INSTALLER_COM}" failonerror="true">
		    <arg value="/rebuild" />
		  	<arg file="src/AdvancedInstaller/MyProject.aip"/>
		 	<arg value="-buildslist" />
	    	<arg value="DefaultBuild;UpdateBuild;AnotherBuild" />
		</exec>
Ionut
Posts: 605
Joined: Tue Nov 22, 2005 11:29 am
Contact: Website

Re: Command line: -buildslist and /SetVersion

Hi,
After trial and error, I found out that this is neither the space nor the colon nor the comma but the semicolon. Please add this simple piece of information to your help file!
You are correct and thank you for bringing this to our attention. The missing information about the builds separator character has been added to the help file.
The next problem was to find out how set the version. Initially I tried to append the /SetVersion command line parameter to the /rebuild command. But it took me a while to find out that this is not possible. Why? It would be so simple.
Note that "/SetVersion", "/AddFile" etc. are editing commands, as opposed to build commands. There is also an example for the "/SetVersion" command in the help guide.

Regards,
Ionut
Denis Toma
Advanced Installer Team
http://www.advancedinstaller.com/

Return to “Common Problems”