With extension Command Variable you can select arguments based on the file path.
{
"version": "0.2.0",
"configurations": [
{
"name": "Python: Current File",
"type": "python",
"request": "launch",
"program": "${file}",
"args" : ["${input:arg1}","${input:arg2}"],
"console": "integratedTerminal"
}
],
"inputs": [
{
"id": "arg1",
"type": "command",
"command": "extension.commandvariable.file.fileAsKey",
"args": {
"/p1.py": "foobar",
"/p2.py": "blabla"
}
},
{
"id": "arg1",
"type": "command",
"command": "extension.commandvariable.file.fileAsKey",
"args": {
"/p1.py": "tralala",
"/p2.py": ""
}
}
]
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…