From 9b7d6fe5be6a68a4954a5f02c877d47086663d39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5kon=20Solbj=C3=B8rg?= Date: Mon, 14 Apr 2025 15:13:16 +0200 Subject: feat: Support reading from (planning output) file --- tech-support/labels/planning_output.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 tech-support/labels/planning_output.py (limited to 'tech-support/labels/planning_output.py') diff --git a/tech-support/labels/planning_output.py b/tech-support/labels/planning_output.py new file mode 100644 index 0000000..934dc83 --- /dev/null +++ b/tech-support/labels/planning_output.py @@ -0,0 +1,14 @@ +from gondul import _match_switches +from gondul import _sort_switches + +def read_planning_switches(path, match=None): + lines = None + with open(path) as f: + lines = f.readlines() + + switches = [] + for line in lines: + switches.append(line.split(" ")[0]) + + switches = _match_switches(switches, match=match) + return _sort_switches(switches) -- cgit v1.2.3