vscode-powershell
vscode-powershell copied to clipboard
add debug configuration for scripts with command-line arguments
Prerequisites
- [X] I have written a descriptive issue title.
- [X] I have searched all issues to ensure it has not already been reported.
Summary
There was a configuration in past for launching debugger for scripts with command-line arguments. It would be nice to have it back.
Proposed Design
{
"type": "PowerShell",
"request": "launch",
"name": "PowerShell Launch Current File w/Args Prompt",
"script": "${file}",
"args": [
"${command:SpecifyScriptArgs}"
],
"cwd": "${file}"
},
${command:SpecifyScriptArgs} still works! You can add it to whatever custom debug configuration you create. I'm not sure it was ever in a provided configuration snippet, as I'm not finding it in the Git history for package.json.
It takes a bit time to find ${command:SpecifyScriptArgs} from documentation. The ready configuration would make it simpler to debug scripts that accept command-line parameters.
It might happen, that the abovementioned configuration was not part of the extension. But I have that in my older repositories and in project scaffolding. And I don't remember from where I got that.