Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added new option to get numeric value of sensor only #34

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

rmtsrc
Copy link

@rmtsrc rmtsrc commented Mar 26, 2015

Returns only the numeric value of the sensor.
Known types: temperature, humidity, "dew point"

@c72578
Copy link

c72578 commented Dec 9, 2019

due-point->dew-point, dew point,

utils/tempered.c Outdated Show resolved Hide resolved
utils/tempered.c Outdated Show resolved Hide resolved
utils/tempered.c Outdated Show resolved Hide resolved
@c72578
Copy link

c72578 commented Dec 10, 2019

Here is a suggestion for updating the PR:

diff --git a/utils/tempered.c b/utils/tempered.c
index 023ca5f..d9b3ab1 100644
--- a/utils/tempered.c
+++ b/utils/tempered.c
@@ -31,9 +31,9 @@ void show_help()
 "Known options:\n"
 "    -h\n"
 "    --help                 Show this help text\n"
-"    -t\n"
-"    --type                 Returns only the numeric value of the sensor.\n"
-"                           Known sensors: temperature, humidity, dew point\n"
+"    -t <type>\n"
+"    --type <type>          Returns only the numeric value of the sensor.\n"
+"                           Known types: temperature, humidity, \"dew point\"\n"
 "    -e\n"
 "    --enumerate            Enumerate the found devices without reading them.\n"
 "    -s <scale>\n"

@c72578
Copy link

c72578 commented Dec 10, 2019

Thanks for updating the PR.
This PR looks pretty useful, to get only the numeric value, which saves parsing or splitting the default, verbose output of tempered.

@c72578
Copy link

c72578 commented Dec 19, 2019

I guess it is intended, that the value is printed without a newline after it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants