From: William D. Jones Date: Sat, 16 Mar 2019 03:14:12 +0000 (-0400) Subject: Choose command separator for tasks based on OS. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b5eb5b3c7837ba7565a06d5079d23b86cc1b85b0;p=SymbiYosys.git Choose command separator for tasks based on OS. Signed-off-by: William D. Jones --- diff --git a/sbysrc/sby_core.py b/sbysrc/sby_core.py index 7db60c8..608cca1 100644 --- a/sbysrc/sby_core.py +++ b/sbysrc/sby_core.py @@ -33,7 +33,19 @@ class SbyTask: self.job = job self.info = info self.deps = deps - self.cmdline = cmdline + if os.name == "posix": + self.cmdline = cmdline + else: + replacements = { + ";" : "&", + "{" : "(", + "}" : ")", + } + + cmdline_copy = cmdline + for u, w in replacements.items(): + cmdline_copy = cmdline_copy.replace(u, w) + self.cmdline = cmdline_copy self.logfile = logfile self.noprintregex = None self.notify = []