From ba7e6925f13f5fa88ec842f701e1ff989339b1a9 Mon Sep 17 00:00:00 2001 From: David Runge Date: Thu, 25 Aug 2016 23:26:51 +0200 Subject: user/compton.service: Adding a check if X is running using xset. Raising RestartSec to 3s. Making service anti-dependant on realtime kernel. --- user/compton.service | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'user') diff --git a/user/compton.service b/user/compton.service index 8b313b5..a8ceb7e 100644 --- a/user/compton.service +++ b/user/compton.service @@ -2,12 +2,15 @@ Description=Compton X Compositor After=display-manager.service local-fs.target ConditionFileIsExecutable=/usr/bin/compton -ConditionFileNotEmpty=/sys/kernel/realtime +ConditionFileIsExecutable=/usr/bin/xset +ConditionFileNotEmpty=!/sys/kernel/realtime [Service] Type=forking +ExecStartPre=/usr/bin/sh -c '/usr/bin/xset q 2>&1 > /dev/null' ExecStart=/usr/bin/compton --config %h/.config/compton.conf -b Restart=always +RestartSec=3s [Install] WantedBy=default.target -- cgit v1.2.3-70-g09d2