aboutsummaryrefslogtreecommitdiff
path: root/gn3/csvcmp.py
diff options
context:
space:
mode:
Diffstat (limited to 'gn3/csvcmp.py')
-rw-r--r--gn3/csvcmp.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/gn3/csvcmp.py b/gn3/csvcmp.py
index ebd323e..360a101 100644
--- a/gn3/csvcmp.py
+++ b/gn3/csvcmp.py
@@ -4,6 +4,13 @@ import uuid
from gn3.commands import run_cmd
+def extract_strain_name(csv_header, data, seek="Strain Name"):
+ for column, value in zip(csv_header.split(","), data.split(",")):
+ if seek in column:
+ return value
+ return ""
+
+
def create_dirs_if_not_exists(dirs: list):
for dir_ in dirs:
if not os.path.exists(dir_):