Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Deleting old file versions during an upgrade install

I am working with a pure InstallScript installation in InstallShield Pro 2010.

A third-party jar file has been replaced with a newer version in our software. When an upgrade installation is run, the new jar is installed, but the old jar also remains. Bad Things ensue.

How can I get InstallShield to update the contents of a folder, AND delete any other files in that location that are not included in the current version?

I've looked at the Component -> Overwrite options, but this only seems to apply "when the installer encounters an existing file with the same name as the one being installed".

Also, I realize that I could add something to the scripts to remove the offending file, but I need a scalable solution. There will be other files replaced over time, and I'd rather not have to manually add a fix to the installer every time this happens.

like image 843
sjohnston Avatar asked Nov 14 '22 07:11

sjohnston


1 Answers

Can you just not change the name of the JAR file from build to build?

I'm not aware of InstallScript having a robocopy /mirror style copy. You'd have to script this behavior and I could see it not ending well quickly.

like image 62
Christopher Painter Avatar answered Mar 07 '23 15:03

Christopher Painter