This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Vars for log() | |
LOGGER="/usr/bin/logger" # Path to logger | |
FACILITY="LOCAL4" # Syslog facility | |
PROG="´basename $0´" # Program name | |
SYSLOG="YES" # Write to Syslog? (YES/NO) | |
VERBOSE="NO" # Write to STDOUT? (YES/NO) | |
# Function: log() | |
# Usage: log priority "message" | |
log() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def tidyDecimalPlaces(value): | |
retval = str(value) | |
if ',' in value: | |
post,pre = value.split(',') | |
if len(pre) == 0: | |
retval = "%s,00" % post | |
elif len(pre) == 1: | |
pre = "%s0" % pre | |
retval = "%s,%s" % (post,pre) | |
else: |
NewerOlder