luisiam / homebridge-cmdswitch2

CMD Plugin for HomeBridge (API 2.0): https://github.com/nfarina/homebridge
Apache License 2.0
176 stars 29 forks source link

stdout stderr #1

Closed smiano33 closed 7 years ago

smiano33 commented 7 years ago

In line 154 of index.js I think the stdout should be stderr. This is for the state_cmd to work. If you echo 0 or 1 into stdout it is a work around.

luisiam commented 7 years ago

I built that assuming most of the people will be using grep for state checking. Even if grep is not able to find any match, it won't return any error and it will return an empty stdout. That's why I am using stdout instead of stderr.