CodePudding user response:
The
8191
-character limit applies to the interactive command line and calls tocmd.exe
's CLI (viacmd /c
)It does not apply to commands invoked from batch files - there the limit is close to
32KiB
(close to32,768
) characters.- However, it still seems to apply selectively to
cmd.exe
's internal commands, such asecho
; by contrast, a call to an external program such aspowershell.exe
is not affected.
- However, it still seems to apply selectively to
As an aside: as clever as the linked method of converting PowerShell scripts to batch files is, the resulting batch files lack support for arguments, and adding that would be far from trivial.