You are not logged in.
I have xmodmap and xset run on .xinitrc to setup my keyboard on login.
But on resume from suspend or hotplug keyboard, I will lose my xset and xmodmap settings.
I'm not lookgind to run a script after resume.
I would like to either set a config file for Xorg/udev or run a script that runs xset, xmodmap when any external keyboard is hotplugged.
I believe udev can do this, but I haven't found any configs for Arch yet.
Any ideas how to achieve hotplug xset/xmodmap?
Last edited by nibblebot (2021-08-07 04:30:08)
Offline
1st: what do you actually configure? Preferably use https://wiki.archlinux.org/title/Xorg/K … tion_files
2nd: https://wiki.archlinux.org/title/Udev#udev_rule_example - you just need to adjust vendor and model ID and the script to run
3rd: https://gist.github.com/AladW/de1c5676d93d05a5a0e1 (for the script you run)
4th. for STR specifically, https://wiki.archlinux.org/title/Power_ … leep_hooks
Offline
Thanks for the ideas. I ended up going with a static configuration.
I swap caps/esc in XkbOptions in my xorg.conf and I launch startx with extra arguments to pass in the key repeat delay and repeat rate.
Those are the only two configurations I was looking for and now I don't need to mess with udev/sleep hooks.
Cheers!
Offline