xsettingsd: correct DISPLAY for the whole script

This commit is contained in:
Vincent Bernat 2020-01-22 22:38:57 +01:00
parent 95bf8a3723
commit d1879ae338

View file

@ -1,5 +1,7 @@
#!/bin/sh
DISPLAY=${DISPLAY%.0}
# Don't try to guess DPI. For a laptop, we don't want the same DPI as
# for an external screen. Just hardcode stuff...
case $(hostname),$(autorandr --current --skip-options gamma) in
@ -20,7 +22,7 @@ change() {
} > ~/.xsettingsd
# Signal xsettingsd
systemctl --user reload xsettingsd@$(systemd-escape -- "${DISPLAY%.0}").service
systemctl --user reload xsettingsd@$(systemd-escape -- "$DISPLAY").service
# Also use xrdb for very old stuff (you know, LibreOffice)
echo Xft.dpi: $dpi | xrdb -merge