diff --git a/cbattery b/cbattery index bf61949..9d41308 100755 --- a/cbattery +++ b/cbattery @@ -19,7 +19,7 @@ EOF } write_cache() { - echo "$1" > "$TMP_FILE" + [[ -n "$NO_CACHE" ]] || echo "$1" > "$TMP_FILE" } read_cache() { diff --git a/cbattery.plist b/cbattery.plist index 451c85f..fb1fe19 100644 --- a/cbattery.plist +++ b/cbattery.plist @@ -10,7 +10,7 @@ ProgramArguments - /opt/homebrew/bin/cbattery + /usr/local/bin/cbattery charging off @@ -20,5 +20,10 @@ StandardErrorPath /tmp/cbattery.stderr + EnvironmentVariables + + NO_CACHE + true +