node-pty
node-pty copied to clipboard
add optional support to replace argv[0] (fixes #472)
trafficstars
Fixes #472.
With this, specifying the new property "argv0" in options will replace argv[0] with a custom string.
This is useful, for example, when starting a login shell:
const pty = spawn('/bin/zsh', [], {
argv0: '-zsh'
});
If this property is omitted, the file parameter is used instead, which is identical to existing behavior.
@microsoft-github-policy-service agree
Hey y’all, let me know if anything’s missing, but I’ve been using this for quite some time now day-to-day and haven’t seen any issues.