diff options
Diffstat (limited to 'scripts/stripreg')
-rwxr-xr-x | scripts/stripreg | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/scripts/stripreg b/scripts/stripreg new file mode 100755 index 00000000..c974e646 --- /dev/null +++ b/scripts/stripreg @@ -0,0 +1,16 @@ +#!/usr/bin/python + +import sys +import re + +print_total = 0 + +def clean(num): + return float(re.sub("(\s+|\$|,)","",num)) + +for line in sys.stdin: + print line[:10], + if print_total: + print clean(line[68:80]) + else: + print clean(line[55:67]) |