From 1324c36585652b7af820b1beb78b4874c629c085 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Sun, 27 Sep 2020 20:47:12 +0200 Subject: Syncidynki --- .scripts/light | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100755 .scripts/light (limited to '.scripts/light') diff --git a/.scripts/light b/.scripts/light new file mode 100755 index 0000000..c8b1001 --- /dev/null +++ b/.scripts/light @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +if [ -n "$1" ]; then + hueadm group 1 =0 &>/dev/null + hueadm group 1 on &>/dev/null + exit 0 +fi + +if [ "$(hueadm group -j 1 | jq .state.any_on)" = "true" ]; then + hueadm group 1 off &>/dev/null +else + hueadm group 1 reset &>/dev/null +fi -- cgit v1.2.3