I'm using manjaro linux with dwm (dynamic window manager) and I need to run some some commands that will only work after the x display server has been started. Lightdm is being used to login.
/usr/bin/xrandr --output eDP1 --auto --right-of HDMI1 /usr/bin/xset r rate 280 40 /usr/bin/copyq
I've tried adding these to
crontab with a delay and
Placing them in
~/.xession did run them but then only the wallpaper loads and the window manager is never started.
Putting them in the user's
crontab gave output such as this:
Can't open display
xset: unable to open display ""
ERROR: QtFatal: This application failed to start because no Qt platform plugin could be initialized.
Where is the appropriate place to put commands such as these?