Is there a standard way to make a program start when a user logs in?
On Ubuntu, for example, you can place a .desktop file in ~/.config/autostart and the application will launch on startup.
Does this apply to other distros as well?
Is there a standard way to make a program start when a user logs in?
On Ubuntu, for example, you can place a .desktop file in ~/.config/autostart and the application will launch on startup.
Does this apply to other distros as well?
This is not distro specific so much as Desktop Environment or Window Manager specific. First of all, there is the situation of users logging into a text console or remote tty via ssh. What gets run when those users login is usually controlled by their shells rc files and the system shell profiles.
Then there is the graphical environment case, which is probably what you are mostly after. Those depend very much on the environment. Gnome has a session manager that handles launching things on login. I assume KDE has something similar.
Other window managers have their own mechanisms, usually starting with some kind of hook in their config files. It is also possible to build your own environment with a script that acts as the login shell that gets run after authenticating, then does whatever background work you want, then fires off a window manager or DE.
Basically, there is no one way. You need to know something about your target environment.