Cannot rerun Java JPackage installer if already installed, second time just exits without warning
No idea if this helps on Mac or Linux but the Windows installer automatically removes older versions of the application when you run it so you just need to set up a scheme which changes the version number on each build to avoid having to ununstall old version each time.
To do this simply you could set the version number as "YY.MM.DDHH" so version number changes each hour and cuts down on uninstalls.
Ant steps:
<tstamp>
<format property="appver" pattern="yy.MM.ddHH" />
</tstamp>
<exec executable="jpackage">
<arg line="--app-version ${appver}"/>
...
</exec>
The CMD version of this:
set appver=%date:~6,2%.%date:~3,2%.%date:~0,2%%time:~0,2%
jpackage --app-version %appver% ...
This may fix the reinstall.
In my case, I create the jpackage installer, install it, creates a new installer (based on Inno Setup) and uninstall the jpackage automatically.
I think what may work in your case is to uninstall the first installation as the installer may detect that it's already installed with the same version.
In my case I do the uninstall automatically with an Ant task
<target name="uninstall" depends="init">
<exec executable="wmic.exe">
<arg value="product" />
<arg value="where" />
<arg value="description='${full.name}'" />
<arg value="uninstall" />
</exec>
</target>