summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2016-03-01 10:13:54 -0500
committerLuke Shumaker <lukeshu@sbcglobal.net>2016-03-01 10:14:50 -0500
commit3788334d9bd085b7048635fe7e7a1b397c2f2ef1 (patch)
treeeb876304068d23b1f16481d1bd8717b93d271645
parent0ebf8c63b0fa3bf3a20eb6e4272290bd0044dbaf (diff)
use flock to avoid xrdb's writing over eachother
-rw-r--r--.config/systemd/user/xresources-dpi@.service3
-rw-r--r--.config/systemd/user/xresources@.service2
2 files changed, 2 insertions, 3 deletions
diff --git a/.config/systemd/user/xresources-dpi@.service b/.config/systemd/user/xresources-dpi@.service
index 0aa2c75..51bb1d5 100644
--- a/.config/systemd/user/xresources-dpi@.service
+++ b/.config/systemd/user/xresources-dpi@.service
@@ -3,13 +3,12 @@ Description=Set the X Resources DataBase DPI to match the display DPI on X displ
Documentation=man:xrdb(1)
Before=X11@%i.target
Requisite=X11@%i.target
-Conflicts=xresources@:i.service # don't run concurrently with another run of xrdb
[Service]
Environment=DISPLAY=%I
Type=oneshot
-ExecStart=/usr/bin/env xrdb-set-dpi
+ExecStart=/usr/bin/env flock ${XDG_RUNTIME_DIR}/x11-xrdb@%I -c xrdb-set-dpi
[Install]
WantedBy=X11@%i.target
diff --git a/.config/systemd/user/xresources@.service b/.config/systemd/user/xresources@.service
index 760fd0f..3d723c6 100644
--- a/.config/systemd/user/xresources@.service
+++ b/.config/systemd/user/xresources@.service
@@ -8,7 +8,7 @@ Requisite=X11@%i.target
Environment=DISPLAY=%I
Type=oneshot
-ExecStart=/usr/bin/env xrdb -merge ${XDG_CONFIG_HOME}/X11/resources
+ExecStart=/usr/bin/env flock ${XDG_RUNTIME_DIR}/x11-xrdb@%I -c 'xrdb -merge ${XDG_CONFIG_HOME}/X11/resources'
[Install]
WantedBy=X11@%i.target