Skip to content

Instantly share code, notes, and snippets.

@rmcc13
Last active June 5, 2019 12:32
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rmcc13/12405e2a559d7e87c8313f5c1ef94c62 to your computer and use it in GitHub Desktop.
Save rmcc13/12405e2a559d7e87c8313f5c1ef94c62 to your computer and use it in GitHub Desktop.
Example configurations for enabling stepping into .NET Core code when debugging in vscode with omnisharp-vscode. The configuration in launch.json and tasks.json is for debugging .NET Core apps. The configuration in settings.json is for debugging tests executed by omnisharp.
{
"version": "0.2.0",
// omnisharp docs reference:
//https://github.com/OmniSharp/omnisharp-vscode/wiki/Debugging-into-the-.NET-Framework-itself
"configurations": [
{
"name": ".NET Core Launch (console)",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
"program": "${workspaceFolder}/<PATH TO APP DLL>",
"console": "internalConsole",
"stopAtEntry": false,
"justMyCode": false,
"symbolOptions": {
"searchMicrosoftSymbolServer": true
},
"searchPaths": [
"https://symbols.nuget.org/download/symbols"
]
"supressJITOptimizations": true,
"env": {
"COMPlus_ZapDisable": "1"
}
}
]
}
{
// omnisharp docs reference:
// https://github.com/OmniSharp/omnisharp-vscode/wiki/How-to-run-and-debug-unit-tests#notes
"csharp.unitTestDebuggingOptions": {
"justMyCode": false,
"symbolOptions": {
"searchMicrosoftSymbolServer": true
},
"searchPaths": [
"https://symbols.nuget.org/download/symbols"
]
"suppressJITOptimizations": true,
"env": {
"COMPlus_ZapDisable": "1"
}
}
}
{
"version": "2.0.0",
"tasks": [
{
"label": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/<PATH TO APP PROJECT>"
],
"problemMatcher": "$msCompile"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment