request#
指示配置节是要启动程序还是要连接到已在运行的实例。
Indicates whether the configuration section is intended to launch
the program or attach
to an already running instance.
args#
启动程序时传递给程序的命令行参数的JSON数组。
JSON array of command-line arguments to pass to the program when it is launched. Example ["arg1", "arg2"]
. If you are escaping characters, you will need to double escape them. For example, ["{\\\"arg1\\\": true}"]
will send {"arg1": true}
to your application.
stopAtEntry#
如果设置为true,则调试器应在目标的入口点停止(附加时忽略)。默认值为false。
If set to true, the debugger should stop at the entry-point of the target (ignored on attach). Default value is false
.
cwd#
设置由调试器启动的应用程序的工作目录。
Sets the working directory of the application launched by the debugger.
environment#
要添加到程序环境中的环境变量。
Environment variables to add to the environment for the program. Example: [ { "name": "config", "value": "Debug" } ]
, not [ { "config": "Debug" } ]
.
externalConsole#
仅在启动调试对象时使用。对于“附加”,此参数不会更改调试对象的行为。
Used only when launching the debuggee. For attach
, this parameter does not change the debuggee's behavior.
MIMode#
指示VS代码将连接到的调试器。必须设置为gdb或lldb。这是基于每个操作系统预先配置的,可以根据需要进行更改。
Indicates the debugger that VS Code will connect to. Must be set to gdb
or lldb
. This is pre-configured on a per-operating system basis and can be changed as needed.
setupCommands#
设置GDB或LLDB所需执行的命令的JSON数组。
JSON array of commands to execute in order to set up the GDB or LLDB. Example: "setupCommands": [ { "text": "target-run", "description": "run target", "ignoreFailures": false }]
.