Skip to content

Commit

Permalink
Chages in desktop_service.py reagrding options management
Browse files Browse the repository at this point in the history
  • Loading branch information
markducks committed Dec 9, 2023
1 parent e60316c commit c21a371
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions embasp/platforms/desktop/desktop_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,10 @@ def run(self):
def start_sync(self, programs, options):
"""Start a new process for the _exe_path and starts solving
syncronously."""
option = ""
option = []
for o in options:
if o is not None:
option += str(o.get_options())
option += str(o.get_separator())
option.append(str(o.get_options()))
else:
print("Warning : wrong " +
str(OptionDescriptor().__class__.__name__))
Expand All @@ -73,19 +72,17 @@ def start_sync(self, programs, options):
return Output("", "Error: executable not found")

exep = str(self._exe_path)
opt = str(option)

lis = list()
lis.append(exep)
if opt != "":
lis.append(opt)
lis.extend(option)
lis.extend(files_paths)
if self._load_from_STDIN_option != "" and final_program != "":
lis.append(self._load_from_STDIN_option)

print(exep + " ", end='')
if opt != "":
print(opt + " ", end='')
if option != []:
print(str(option) + " ", end='')
for path in files_paths:
print(path + " ", end='')
if final_program != "":
Expand Down

0 comments on commit c21a371

Please sign in to comment.