Startup ~/.xprofile vs ~/.config/openbox/autostart?

I am pretty sure that I can put most things in either, but what is the difference?

Is it true that, for instance, if I have openbox and i3, then anything in .xprofile will happen for both WM sessions, but stuff in the autostart file will only happen in an OB session?

And, similarly for /home/leigh/.config/i3/config ?


You are correct. .xprofile for every X session, autostart/config files window manager specific.

For example, put tint2 in the openbox autostart because it doesn’t work well with i3.

But put things like your left-handed mouse setup in .xprofile so it’s always available.


Thanks @PackRat

what about app startups?
and things like bluetooth tray etc?

You can define those sorts of things in your .xinitrc or .xprofile.

For example, Blueman applet is started:

blueman-applet &

All of these entries must be defined before any exec command. I’m really talking about .xinitrc here, as I don’t use .xprofile myself.

The & is crucial to include, otherwise it just keeps executing.

Arch Wiki Xinit. They give an example there of what I am rabbiting on about.


Like @Dobbie03 says.

Comes down if it’s window manager specific or not.


@Dobbie03 why do you use .xinitrc and not .xprofile?
I’m just interested - irealise its all personal choice but interested to know what are the pros and cons

@PackRat thanks. I have now moved most things to .xprofile ready for setting up i3 as an alternative WM to OB

Because I just always have. No reason other than that.

Also I had no idea that .xprofile does the same thing for launching programs.

1 Like

:smiley: Thanks @Dobbie03

1 Like