From 96902aee6b4320a5e374435fe28ae96607ccc59d Mon Sep 17 00:00:00 2001 From: Joe Groocock Date: Sun, 22 Mar 2020 12:35:16 +0000 Subject: [PATCH] X11: don't fail xprofile when xmodmap is absent --- .config/X11/xprofile | 4 +++- .config/systemd/user/xprofile.service | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.config/X11/xprofile b/.config/X11/xprofile index 4c41bc6..01d528a 100644 --- a/.config/X11/xprofile +++ b/.config/X11/xprofile @@ -19,4 +19,6 @@ xrandr --dpi $(xrdb -query | grep -i xft.dpi | cut -d: -f2) setxkbmap -option caps:none xset r rate 200 18 -xmodmap "$XDG_CONFIG_HOME"/X11/xmodmap + +test -f "$XDG_CONFIG_HOME"/X11/xmodmap && \ + xmodmap "$XDG_CONFIG_HOME"/X11/xmodmap diff --git a/.config/systemd/user/xprofile.service b/.config/systemd/user/xprofile.service index e3ab653..63eaf40 100644 --- a/.config/systemd/user/xprofile.service +++ b/.config/systemd/user/xprofile.service @@ -7,7 +7,7 @@ After=xorg.target profile.service [Service] Type=oneshot RemainAfterExit=yes -ExecStart=/usr/bin/bash -cx '. $XDG_CONFIG_HOME/X11/xprofile && systemctl --user import-environment' +ExecStart=/usr/bin/bash -c '. $XDG_CONFIG_HOME/X11/xprofile; systemctl --user import-environment' [Install] WantedBy=xorg.target