(script: string)
| 2877 | } |
| 2878 | |
| 2879 | function nodeCommand(script: string): string { |
| 2880 | const payload = Buffer.from(script, 'utf8').toString('base64'); |
| 2881 | const bootstrap = `eval(Buffer.from('${payload}','base64').toString('utf8'))`; |
| 2882 | const shell = defaultShellPlan(); |
| 2883 | if (shell.kind === 'pwsh' || shell.kind === 'powershell') { |
| 2884 | return `& ${powerShellQuote(process.execPath)} -e ${powerShellQuote(bootstrap)}`; |
| 2885 | } |
| 2886 | if (shell.kind === 'cmd') { |
| 2887 | return `${cmdQuote(process.execPath)} -e ${cmdQuote(bootstrap)}`; |
| 2888 | } |
| 2889 | return `${shellQuote(process.execPath)} -e ${shellQuote(bootstrap)}`; |
| 2890 | } |
| 2891 | |
| 2892 | function waitForeverCommand(ready = ''): string { |
| 2893 | return nodeCommand(` |
no test coverage detected