Skip to content

Instantly share code, notes, and snippets.

@mmas
Created July 5, 2017 00:00
Show Gist options
  • Save mmas/e57d69932587fee76c317197c90f0b7d to your computer and use it in GitHub Desktop.
Save mmas/e57d69932587fee76c317197c90f0b7d to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
import sys
for line in sys.stdin:
if not line.strip() or line.startswith('Wban'):
continue
_, k, v = line[:17].split(',', 2)
try:
v = int(v)
except ValueError:
continue
print '%s\t%s' % (k, v)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment