diff options
-rwxr-xr-x | set.sh | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -51,7 +51,11 @@ while [[ $# -gt 0 ]]; do br) [[ $# -lt 2 ]] && { echo >&2 "Not enough arguments to 'br' command"; exit 1; } - commandstr="$commandstr * {dimming:{brightness:$2}}" + if [[ $2 -gt 0 ]]; then + commandstr="$commandstr * {on:{on:true}, dimming:{brightness:$2}}" + else + commandstr="$commandstr * {on:{on:false}}" + fi shift 2 ;; |