1

Update gdm-update-display-settings utility script

This commit is contained in:
Jessie Hildebrandt 2023-06-02 08:50:40 -04:00
parent 38fe1bd45d
commit 80d85781d3

11
scripts/gdm-update-display-settings Normal file → Executable file
View File

@ -8,3 +8,14 @@
################################################################################
sudo cp .config/monitors.xml /var/lib/gdm/.config/ && echo "Copied .config/monitors.xml to /var/lib/gdm/.config"
MOUSE_SPEED=$(gsettings get org.gnome.desktop.peripherals.mouse speed)
MOUSE_ACCEL_PROFILE=$(gsettings get org.gnome.desktop.peripherals.mouse accel-profile)
TOUCHPAD_SPEED=$(gsettings get org.gnome.desktop.peripherals.touchpad speed)
TOUCHPAD_ACCEL_PROFILE=$(gsettings get org.gnome.desktop.peripherals.touchpad accel-profile)
sudo su -c \
"sudo -u gdm dbus-launch gsettings set org.gnome.desktop.peripherals.mouse speed ${MOUSE_SPEED} &&
sudo -u gdm dbus-launch gsettings set org.gnome.desktop.peripherals.mouse accel-profile "${MOUSE_ACCEL_PROFILE}" &&
sudo -u gdm dbus-launch gsettings set org.gnome.desktop.peripherals.touchpad speed ${TOUCHPAD_SPEED} &&
sudo -u gdm dbus-launch gsettings set org.gnome.desktop.peripherals.touchpad accel-profile "${TOUCHPAD_ACCEL_PROFILE}" &&
echo Applied pointer speed and acceleration profiles"