Test if per-host scripts dir exists before trying to access it
authorSiraaj Khandkar <siraaj@khandkar.net>
Mon, 18 Jul 2022 15:07:27 +0000 (15:07 +0000)
committerSiraaj Khandkar <siraaj@khandkar.net>
Mon, 18 Jul 2022 15:07:27 +0000 (15:07 +0000)
home/.xlaunch

index be3cc36..213e0b2 100755 (executable)
@@ -15,9 +15,14 @@ launch_common() {
 
 launch_specialized() {
     # XXX dunst lazily started by dbus
 
 launch_specialized() {
     # XXX dunst lazily started by dbus
-    for script in ~/.xlaunch.d."$(hostname)"/*; do
-        "$script"
-    done
+    local -r scripts_dir=~/.xlaunch.d."$(hostname)"
+
+    if test -f "$scripts_dir"
+    then
+        for script in "$scripts_dir"/*; do
+            "$script"
+        done
+    fi
 }
 
 launch_common
 }
 
 launch_common
This page took 0.028681 seconds and 4 git commands to generate.