Skip to content

Commit 4993472

Browse files
committed
fixes for cmd wrapper
1 parent 4f46ba2 commit 4993472

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

lib/envstack/wrapper.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -227,16 +227,16 @@ def __init__(self, namespace=config.DEFAULT_NAMESPACE, args=[]):
227227
"""
228228
super(CmdWrapper, self).__init__(namespace, args)
229229
self.args = ["/c", self.cmd]
230-
self.shell = False
230+
self.shell = True
231231

232-
def get_subprocess_args(self, cmd):
233-
"""Returns the arguments to be passed to the subprocess."""
234-
return [cmd] + self.args
232+
# def get_subprocess_args(self, cmd):
233+
# """Returns the arguments to be passed to the subprocess."""
234+
# return [cmd] + self.args
235235

236-
def executable(self):
237-
"""Returns the shell command to run the original command."""
238-
self.cmd = config.SHELL
239-
return self.cmd
236+
# def executable(self):
237+
# """Returns the shell command to run the original command."""
238+
# self.cmd = config.SHELL
239+
# return self.cmd
240240

241241

242242
def run_command(command: str, namespace: str = config.DEFAULT_NAMESPACE):
@@ -286,7 +286,7 @@ def run_command(command: str, namespace: str = config.DEFAULT_NAMESPACE):
286286

287287
if shellname in ["cmd"]:
288288
# windows behavior preserved (if you need it)
289-
expr = re.sub(r"\{(\w+)\}", r"%\1%", " ".join(argv))
290-
return CmdWrapper(namespace, expr).launch()
289+
# expr = re.sub(r"\{(\w+)\}", r"%\1%", " ".join(argv))
290+
return CmdWrapper(namespace, argv).launch()
291291

292292
return CommandWrapper(namespace, argv).launch()

0 commit comments

Comments
 (0)