diff --git a/50-dotool.conf b/50-dotool.conf new file mode 100644 index 0000000..e64880e --- /dev/null +++ b/50-dotool.conf @@ -0,0 +1,6 @@ +# This can stop dotool typing guff if you are using a non-us keyboard layout. +Section "InputClass" + Identifier "dotool keyboard" + MatchDriver "libinput" + Option "XkbLayout" "us" +EndSection diff --git a/80-dotool.rules b/80-dotool.rules index b95dca1..0b235e9 100644 --- a/80-dotool.rules +++ b/80-dotool.rules @@ -1,6 +1,6 @@ # This allows users in group input to use dotool without root permissions. KERNEL=="uinput", GROUP="input", MODE="0660", OPTIONS+="static_node=uinput" -# This can stop dotool typing guff if you are using a non-us keyboard layout. -# It only seems to affect X11. +# This can stop dotool typing guff if you are using a non-us keyboard layout, +# but it only seems to affect X and 50-dotool.conf achieves that better. SUBSYSTEM=="input", ACTION=="add|change", ATTRS{name}=="dotool keyboard", ENV{XKBLAYOUT}="us" diff --git a/install.sh b/install.sh index 3a2e72c..bcc8c6e 100755 --- a/install.sh +++ b/install.sh @@ -6,4 +6,6 @@ mkdir -p "$1/${2:-usr/local/bin}" || exit cp -v dotool dotoolc dotoold "$1/${2:-usr/local/bin}" || exit mkdir -p "$1/etc/udev/rules.d" || exit cp -v 80-dotool.rules "$1/etc/udev/rules.d" || exit +mkdir -p "$1/usr/share/X11/xorg.conf.d" || exit +cp -v 50-dotool.conf "$1/usr/share/X11/xorg.conf.d" || exit udevadm trigger