vscode 多模块 debug

vscode 多模块 debug

.vscode/launch.json 配置

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "itsm",
            "type": "go",
            "request": "launch",
            "mode": "auto",
            "program": "${workspaceFolder}/apps/app1",
            "debugAdapter": "legacy",
        },
        {
            "name": "apiserv",
            "type": "go",
            "request": "launch",
            "mode": "auto",
            "program": "${workspaceFolder}/apps/app2",
            "debugAdapter": "legacy",
        },
    ],
    "compounds": [
        {
            "name": "mutilApp",
            "configurations": ["app1", "app2"],
            "preLaunchTask": "${defaultBuildTask}",
            "stopAll": true
        }
    ]
}'

启动

vscode 多模块 debug_第1张图片

你可能感兴趣的:(开发小技巧,ide,编辑器,vscode,debug)