Install4j - unistalling linux application - install4j

I'm making multiplatform(win and linux without GUI) installer for my application - using install4j.
Install4j creates application.sh installation file. When I run this sh file - my application is installed on linux machine. But whats the correct way how to uninstall my application? No uninstaller.sh was created. Should I run application.sh with some additions arguments? Thanks

The uninstaller is created wherever you specify it. On Installer->Screens & Actions, select the "Uninstaller" and check its "Executable name" and "Executable directory" properties.

Related

Install4j - creating a startup folder item

I have a multi-platform app and install4j creates installers for both Windows and macOS. One of the programs I'm deploying I would like added to the startup folder for Windows ONLY - not MacOS.
Is there a condition expression that I can put in the screen below which will allow the installer to determine if it's running on Windows and only add the launcher to automatically start for that OS and not macOS?
The condition expression you are looking for is
Util.isWindows()

How do I check if the installed program is running at the beginning of the install4j uninstaller?

I have a Java program (Eclipse RCP in case that matters) that is installed and uninstalled with install4j. This works fine, except that the uninstaller will happily uninstall (most of) my program while it is running, leading to an incomplete uninstall and a program crash (with potential data loss).
I would like the uninstaller to check whether the program is running before deleting any files, and prompt the user to exit the program if necessary.
I could not find any options to supports this in the install4j documentation or forums.
On stackoverflow I found answers for NSIS and Inno, but not for install4j.
Can this be done with install4j, or do I need custom code? Do I have to make my program react to requests/messages to make it detectable?
You can add a "Check for running processes" action before the "Uninstall files" action.

install4j 6.1.6 Installer remote debugging

I have generated an install4j Windows installer. I want the installer to run on a remote Windows machine and have to debug the installation process. The installed JVM is 1.8_161. I have tried several option in my vmoptions file:
-Xdebug
-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=9999
or
-Xdebug
-Xnoagent
-Djava.compiler=NONE
-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=9999
Neither configuration works. The vmoptions' file name is the same as the media file's name except the extension.
I hadn't any problems with debugging earlier remote installers.
Best regards
anko
The installer does not read a .vmoptions file for security reasons, because installers are often saved in writable locations when they are downloaded.
You have to pass -J-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=9999 on the command line (note the -J prefix)

Can install4j ignore previously installations on reinstall/upgrade for default directory?

How can I get my install4j installer to always suggest the default installation and not try to use the previous installation directory.
I added my directory to the media and checked Suggest Application directory on the Installation Location screen but I'm still getting undesirable behavior.
Wanted behavior:
user installed C:\Program Files\My App 1.0.0\
use runs installer for 2.0 and it prompts with C:\Program Files\My App 2.0.0\
Current behavior:
user installed C:\Program Files\My App 1.0.0\
use runs installer for 2.0 and it prompts with C:\Program Files\My App 1.0.0\
Thanks for the help
Peter
On Installer->Update Options, deselect the check box "Detect previous installation directory".

Place shortcut to application in autostart folder with Install4J

I'm using Install4J to build my application.
Is there a way to make Install4J copy (make shortcut to) the created application to the autostart directory in windows?
I know there is a installer variable called sys.startupDir, which should point to the autostart directory, I just don't know how to make an action/script that does what I want.
There is an "Add startup executable" action in install4j which does what you want. It even works on Mac OS X as well.