📜  在 vscode 中调试多个应用程序 - 任何代码示例

📅  最后修改于: 2022-03-11 14:55:54.054000             🧑  作者: Mango

代码示例1
{
    "version": "0.2.0",
    "configurations": [
        {
            "name": ".NET Core Launch (web-api)",
            "type": "coreclr",
            "request": "launch",
            "preLaunchTask": "buildapi",            
            "program": "${workspaceFolder}/serviceflow.api/bin/Debug/netcoreapp2.2/serviceflow.api.dll",
            "args": [],
            "cwd": "${workspaceFolder}/serviceflow.api",
            "stopAtEntry": false,
            "internalConsoleOptions": "openOnSessionStart",
            "launchBrowser": {
                "enabled": false,
                "args": "${auto-detect-url}",
                "windows": {
                    "command": "cmd.exe",
                    "args": "/C start ${auto-detect-url}"
                },
                "osx": {
                    "command": "open"
                },
                "linux": {
                    "command": "xdg-open"
                }
            },
            "env": {
                "ASPNETCORE_ENVIRONMENT": "Development",
                "ASPNETCORE_URLS": "https://localhost:5001"
            },
            "sourceFileMap": {
                "/Views": "${workspaceFolder}/Views"
            }
        },

        {
            "name": ".NET Core Launch (web)",
            "type": "coreclr",
            "request": "launch",
            "preLaunchTask": "buildweb",            
            "program": "${workspaceFolder}/serviceflow.web/bin/Debug/netcoreapp2.2/serviceflow.web.dll",
            "args": [],
            "cwd": "${workspaceFolder}/serviceflow.web",
            "stopAtEntry": false,
            "internalConsoleOptions": "openOnSessionStart",
            "launchBrowser": {
                "enabled": true,
                "args": "${auto-detect-url}",
                "windows": {
                    "command": "cmd.exe",
                    "args": "/C start ${auto-detect-url}"
                },
                "osx": {
                    "command": "open"
                },
                "linux": {
                    "command": "xdg-open"
                }
            },
            "env": {
                "ASPNETCORE_ENVIRONMENT": "Development",
                "ASPNETCORE_URLS": "https://localhost:6001"
            },
            "sourceFileMap": {
                "/Views": "${workspaceFolder}/Views"
            }
        },
        {
            "name": ".NET Core Attach",
            "type": "coreclr",
            "request": "attach",
            "processId": "${command:pickProcess}"
        },
    ]
}