summaryrefslogtreecommitdiff
path: root/gpsprof
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2010-04-21 13:34:24 -0700
committerGary E. Miller <gem@rellim.com>2010-04-21 13:34:24 -0700
commit0386ca6c4d3a8f755b813bcc32b11ea9c4f6e012 (patch)
treed93648d53a0d01f1fce899c4a0e18cd7639b92c4 /gpsprof
parentf69dcdb5e2fe181f6ede50ae4840e3892891f210 (diff)
downloadgpsd-0386ca6c4d3a8f755b813bcc32b11ea9c4f6e012.tar.gz
Patch to make gpsprof use the same -D as the other gpsd helper programs.
With man page update. Signed-off-by: Gary E. Miller <gem@rellim.com>
Diffstat (limited to 'gpsprof')
-rwxr-xr-xgpsprof9
1 files changed, 5 insertions, 4 deletions
diff --git a/gpsprof b/gpsprof
index 2f7738d0..33d7db2c 100755
--- a/gpsprof
+++ b/gpsprof
@@ -451,7 +451,8 @@ def plotframe(await, fname, speed, threshold, title):
if __name__ == '__main__':
try:
- (options, arguments) = getopt.getopt(sys.argv[1:], "f:hm:n:s:t:v")
+ (options, arguments) = getopt.getopt(sys.argv[1:], "f:hm:n:s:t:D:")
+
formatter = "space"
raw = False
speed = 0
@@ -470,11 +471,11 @@ if __name__ == '__main__':
speed = int(val)
elif (switch == '-t'):
title = val
- elif (switch == '-v'):
- verbose += 1
+ elif (switch == '-D'):
+ verbose = int(val)
elif (switch == '-h'):
sys.stderr.write(\
- "usage: gpsprof [ [-v[v] -h] [-m threshold] [-n samplecount] \n"
+ "usage: gpsprof [-h] [-D debuglevel] [-m threshold] [-n samplecount] \n"
+ "\t[-f {" + "|".join(map(lambda x: x.name, formatters)) + "}] [-s speed] [-t title]\n")
sys.exit(0)
sys.stdout.write(plotframe(await,formatter,speed,threshold,title))