I just reinstalled Kubuntu 7.04 on the Linux box after having upgraded successively from Ubuntu 6.06. I wanted to clean house a bit and get rid of any unnecessary Gnome leftovers. While setting things up I was trying to remember how I had gotten the little system tray application checkgmail to run at startup every time.
This flummoxed me for several hours, while I surfed the web and the Ubuntu forums. I found a reasonably relevant FAQ here, but that only dealt with the Gnome desktop or with running a script at boot time, which I did not want either. Anyway, to make a long story short, I eventually remembered the KDE solution to the problem, and I’ll post it here so I don’t forget again.
(1) Create a shell script, using Kate or nano or whatever. In my case, all the script does is execute the checkgmail command, which starts the application.
#!/bin/bash checkgmail
(2) Save the script as mystartupscript (or whatever) and drop it into KDE’s Autostart directory, which is located in the (hidden) /.kde directory in your home folder.
$ mv mystartupscript /home/username/.kde/Autostart
(3) Make the script executable.
$ chmod 755 /home/username/.kde/Autostart/mystartupscript
Done! Now reboot or logout and the next time KDE starts, your script will run after the KDE desktop loads. Cake.
