mirror of
https://github.com/danbulant/nushell
synced 2026-05-20 12:58:32 +00:00
Build our own args before shelling
This commit is contained in:
parent
e73f489aeb
commit
29bc4985fc
1 changed files with 6 additions and 2 deletions
|
|
@ -122,8 +122,12 @@ impl ExternalCommand {
|
|||
input: ClassifiedInputStream,
|
||||
stream_next: StreamNext,
|
||||
) -> Result<ClassifiedInputStream, ShellError> {
|
||||
let process = Exec::shell(&self.name)
|
||||
.args(&self.args)
|
||||
let mut cmd = self.name.clone();
|
||||
for arg in self.args {
|
||||
cmd.push_str(" ");
|
||||
cmd.push_str(&arg);
|
||||
}
|
||||
let process = Exec::shell(&cmd)
|
||||
.cwd(context.env.lock().unwrap().cwd());
|
||||
|
||||
let mut process = match stream_next {
|
||||
|
|
|
|||
Loading…
Reference in a new issue