G'day haukex,
"Just a small nitpick: on Windows it is almost impossible to avoid the shell."
I checked out that module's documentation and code not so long; I've just checked again. Both are still very clear that capturex() does not invoke the shell. Here's a selection of extracts (non-exhaustive):
From SYNOPSIS:
# As above, but NEVER invokes the shell. my $output = capturex("some_command", @args);
From source, starting at Line 361 (note the "NO_SHELL"):
# capturex() is just like backticks/qx, but never invokes the shell. sub capturex { ... if (WINDOWS) { return _win32_capture(NO_SHELL, $valid_returns, $command, +@args); }
Are you possibly confusing capturex() with capture()? Same source, starting at Line 220 (note the "USE_SHELL"):
# capture is our way of running a process with backticks/qx semantics sub capture { ... if (WINDOWS) { # USE_SHELL really means "You may use the shell if you nee +d it." return _win32_capture(USE_SHELL, $valid_returns, $command) +; }
If not a case of confusion, do you think the documentation, code, or something else, is wrong?
All links and extracts are from the IPC-System-Simple-1.30 distribution (released "Mar 24, 2020").
— Ken
In reply to Re^3: use of Backticks to catch console output
by kcott
in thread use of Backticks to catch console output
by Takamoto
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |