I want to launch a java application when the system starts , so I created the
.autostart directory in the
~/ directory. Now what should I do to make the java application starts with the system ?
You need to create an executable bash script. For example:
java Yourcompiledcode in
mystartupscript.sh and make the sh file executable by running
chmod +x mystartupscript.sh. Just make sure that the script is in the correct directory.
EDIT 1: In
KDE you have the
~/.kde/Autostart folder where you put in your scripts, which run after kde startup. In Ubuntu, you are probably using
Gnome3, so you'd have to create a folder
~/.config/autostart and put the script in there
Afaik, you just have to put an executable into that folder. But why don't you use the autostart manager?
System > Settings > Autostart
Btw. I think this belongs to Askubuntu