Clear MPD state on non-0 exit from MPD song sensor
[khatus.git] / bin / khatus_parse_bluetoothctl_show
index 08a8708..ed1e228 100755 (executable)
@@ -8,7 +8,7 @@
 /^\t[A-Z][A-Za-z]+:/ {
     key = $1
     sub(":$", "", key)
-    sub("^" $1, "")
+    sub("^\t" $1 " *", "")
     val = $0
     data[controller, key] = val
 }
@@ -26,7 +26,7 @@ END {
             show = "ERROR"
         }
     } else {
-        show = "off"  # TODO: Perhaps use differentiated marker?
+        show = "n/a"
     }
     print(show)
 }
This page took 0.028787 seconds and 4 git commands to generate.