diff --git a/src/parser.py b/src/parser.py index d553fa5..0341fe1 100644 --- a/src/parser.py +++ b/src/parser.py @@ -45,6 +45,11 @@ class Parser(object): if value := opt.get("value"): if isinstance(value, bool): pair += f'="{str(value).lower()}"' + elif isinstance(value, (int, float)): + pair += f"={value}" # Numbers should not be quoted + elif isinstance(value, list): + formatted_list = ",".join(map(str, value)) + pair += f'="[ {formatted_list} ]"' # Preserve list format else: pair += f'="{value}"' return pair