trackpoint accel script

This commit is contained in:
Sridhar Ratnakumar 2021-11-20 12:02:15 -05:00
parent 80d08d67eb
commit 5914b1aefb

View file

@ -1,5 +1,9 @@
{ config, pkgs, ... }:
let
fixTrackpointAccelCli =
"${pkgs.xorg.xinput} --set-prop 'TPPS/2 Elan TrackPoint' 'libinput Accel Speed' 0.7";
in
{
# NOTE: libinput changes require a reboot
services.xserver.libinput = {
@ -17,17 +21,22 @@
hardware.trackpoint = {
enable = true;
device = "TPPS/2 Elan TrackPoint"; # Check with `xinput`
# FIXME: This doesn't have any effect. Wheras `xinput set-prop` (on CLI) does.
# FIXME: This doesn't have any effect. Whereas `xinput set-prop` (on CLI) does. See fixTrackpointAccelCli
#sensitivity = 240;
#speed = 250;
};
# Automating the aforementioned `xinput set-prop` ...
services.xserver.displayManager.sessionCommands = ''
${pkgs.xorg.xinput} --set-prop 'TPPS/2 Elan TrackPoint' 'libinput Accel Speed' 0.8
${fixTrackpointAccelCli}
'';
environment.systemPackages = with pkgs; [
libinput # libinput CLI
(pkgs.writeScriptBin "fix-trackpoint-accel"
''
#!${pkgs.runtimeShell}
${fixTrackpointAccelCli}
'')
];
}