From ed243f0f928496c39d031825acbfe801fbe8c212 Mon Sep 17 00:00:00 2001 From: Marc Mance Date: Wed, 31 Jul 2024 13:07:50 -0400 Subject: [PATCH] changed top command to remove ansi --- collect.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/collect.py b/collect.py index 3e17b46..92e0118 100644 --- a/collect.py +++ b/collect.py @@ -100,14 +100,8 @@ def convert_to_megabytes(data_size): return int(size * unit_map[unit]) -def remove_ansi_escape(text): - """Removes ANSI escape sequences from a string.""" - ansi_escape = re.compile(r"\x1B(?:[@-Z\\^[\]m])+") - return ansi_escape.sub("", text) - - def scaleMemstat(): - command = ["top", "-n", "1"] + command = ["top", "-bn", "1"] filename = "memStat.csv" collect = runCollect(command)