This commit is contained in:
2Shirt 2019-01-07 16:13:24 -07:00
parent b1e5727d54
commit 83e96f9135
Signed by: 2Shirt
GPG key ID: 152FAC923B0E132C

View file

@ -14,7 +14,7 @@ KNOWN_DEV_TYPES = ('CPU', 'Disk')
# Regex
REGEX_BLOCK_GRAPH = re.compile(r'(▁|▂|▃|▄|▅|▆|▇|█)')
REGEX_NVME_SMART_ATTRIBUTES = re.compile(r'^\s*(\d+) / (\w+): (.{28})(.*)$')
REGEX_TEMPS = re.compile(r'^\s*(.*?)\s+(idle.*)$')
REGEX_TEMPS = re.compile(r'^\s*(.*?)\s+(idle:)(.*)$')
REGEX_SENSOR = re.compile(r'^(.*?)(\s*)$')
@ -113,6 +113,7 @@ class osTicket():
if r:
_sensor = '{:<20}'.format(r.group(1))
_temps = r.group(2)
_temps += re.sub(r'\s+(\w+:)', r' ...... \1', r.group(3))
r2 = REGEX_SENSOR.match(_sensor)
_sensor = r2.group(1)
_spacer = pad_with_dots(r2.group(2))