nixCraft Poll

Topics

Linux desktop auto start or launch programs

Posted by Vivek Gite [Last updated: November 29, 2006]

So how do you automatically start or launch program when you login into your KDE desktop system? For example if you would like to start program called xawtv (to watch tv) and mozilla-thunderbird mail client program.

This tip explains how to run programs to launch when you login into KDE or Gnome desktop systems.

KDE

If you are using KDE under any Linux distribution drop/copy program file to ~/.kde/Autostart directory. If your user name is tom create a soft link or copy binary in /home/tom/.kde/Autostart directory. Please note that the symbol ~ indicate the users home directory.

First change directory to ~/.kde/Autostart
$ cd ~/.kde/Autostart

Now create a symbolic link for xawtv program:
Type the following command to make a link (soft) to xawtv program:
$ ln -s $(which xawtv) .
Now create a link (soft) for mozilla-thunderbird mail client:
$ ln -s $(which mozilla-thunderbird) .

General syntax to create softlink to autostart program under KDE is as follows:
ln -s $(which linux-command-name) .

GNOME

Under GNOME Desktop system:
Open control center > Sessions > Startup Programs.

Now add your programs. Another option is to add programs in ~/.gnome2/session-manual file.

Finally you can also add program names to ~/.xinitrc file. This is useful for lightweight Window Manger such as Fluxbox or X session started by startx.
Open .xinitrc file:
$ vi ~/.xinitrc
Append program name:
/usr/bin/xawtv &

Save and close file.

Want to stay up to date with the latest Linux tips, news and announcements? Subscribe to our free e-mail newsletter or RSS feed to get all updates. You can Email this page to a friend.

You may also be interested in other helpful articles:

Leave a Reply

We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word

Copyright © 2004-2008 nixCraft. All rights reserved - TOS/Disclaimer - Privacy policy - Sitemap - Powered by Open source software.