Skip to content

Commit d4e1117

Browse files
Respond to feedback for debugger.md
This makes some improvements to debugger.md based on feedback from Noah and Andrew.
1 parent 434ed4e commit d4e1117

File tree

1 file changed

+20
-5
lines changed

1 file changed

+20
-5
lines changed

debugger.md

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,23 @@ This page gives you detailed instructions on how to debug code running under .NE
55
File bugs and feature requests [here](https://github.com/OmniSharp/omnisharp-vscode/issues) and [join our insiders group](http://landinghub.visualstudio.com/dotnetcoreinsiders) to help us build great tooling for .NET Core.
66

77
####Requirements
8-
* Only works with the RC2 version of .NET Core
8+
* Requires .NET Core RC2 (will not work with earlier versions)
99
* X64 only
1010
* Supports OSX, Ubuntu 14.04, Red Hat Enterprise Linux 7.2, Debian 8.2, Centos 7.1, and Windows 7+
1111

1212
###First Time setup
1313
##### 1: Get Visual Studio Code
14-
Install Visual Studio Code (VSC). Pick the latest VSC version from here: https://code.visualstudio.com Make sure it is at least 0.10.10.
14+
Install Visual Studio Code (VSC). Pick the latest VSC version from here: https://code.visualstudio.com Make sure it is at least 0.10.10.
15+
16+
If you are not sure what version you have, you can see your version of VS Code:
17+
18+
* **OSX:** Code->Abort Visual Studio Code
19+
* **Windows / Linux:** Help->Abort
1520

1621
##### 2: Install .NET command line tools
1722
Install the .NET Core command line tools (CLI) by following the installation part of the instructions here: http://dotnet.github.io/getting-started
1823

19-
**Hint for Mac**: .NET Core requires openSSL to work. Don't forget this! Execute: `brew install openssl`
24+
**OSX:** .NET Core requires openSSL to work. Don't forget this! Execute: `brew install openssl`
2025

2126
##### 3: Install C# Extension for VS Code
2227
Open the command palette in VS Code (F1) and type "ext install C#" to trigger the installation of the extension. VS Code will show a message that the extension has been installed and it will restart.
@@ -45,14 +50,19 @@ You can also find some example projects on https://github.com/aspnet/cli-samples
4550
Go to File->Open and open the directory in Visual Studio Code. If this is the first time that the C# extension has been activated, it will now download additional platform-specific dependencies.
4651

4752
##### 3: Add VS Code configuration files to the workspace
48-
VS Code needs to be configured so it understands how to build your project and debug it. For this there are two files which need to be added -- .vscode/tasks.json and .vscode/launch.json. Tasks.json is used to configure what command line command is executed to build your project, and launch.json configures the type of debugger you want to use, and what program should be run under that debugger. Launch.json also configures VS Code to run the build task from tasks.json so that your program is automatically up-to-date each time you go to debug it.
53+
VS Code needs to be configured so it understands how to build your project and debug it. For this there are two files which need to be added -- .vscode/tasks.json and .vscode/launch.json.
54+
55+
* Tasks.json is used to configure what command line command is executed to build your project, and launch.json configures the type of debugger you want to use, and what program should be run under that debugger.
56+
* Launch.json configures VS Code to run the build task from tasks.json so that your program is automatically up-to-date each time you go to debug it.
4957

5058
For most projects, the C# extension can automatically generate these files for you. When you open a project and the C# extension is installed, you should see the following prompt in VS Code:
5159

5260
![Info: Required assets to build and debug are missing from your project. Add them? Yes | Close](https://raw.githubusercontent.com/wiki/OmniSharp/omnisharp-vscode/images/info-bar-add-required-assets.png)
5361

5462
Clicking 'Yes' on this prompt should add these resources.
5563

64+
**Creating configuration files manually**
65+
5666
In case you would rather generate .vscode/tasks.json by hand, you can start with [this example](https://raw.githubusercontent.com/wiki/OmniSharp/omnisharp-vscode/ExampleCode/tasks.json) which configures VS Code to launch 'dotnet build'. If you don't want to build from VS Code at all, you can skip this file. If you do this, you will need to comment out the 'preLaunchTask' from .vscode/launch.json when you create it.
5767

5868
In case you would rather generate .vscode/launch.json by hand, when you want to start debugging, press the debugger play button (or hit F5) as you would normally do. VS Code will provide a list of templates to select from. Pick ".NET Core" from this list and the edit the 'program' property to indicate the path to the application dll or .NET Core host executable to launch.
@@ -78,10 +88,15 @@ Now open the configuration drop down from the top and select the one you want.
7888

7989
####More things to configure In launch.json
8090
#####Just My Code
81-
You can optionally disable justMyCode by setting it to "false".
91+
You can optionally disable justMyCode by setting it to "false". You should disable Just My Code when you are trying to debug into a library that you pulled down which doesn't have symbols or is optimized.
8292

8393
"justMyCode":false*
8494

95+
Just My Code is a set of features that makes it easier to focus on debugging your code by hiding some of the details of optimized libraries that you might be using, like the .NET Framework itself. The most important sub parts of this feature are --
96+
97+
* User-unhandled exceptions: automatically stop the debugger just before exceptions are about to be caught by the framework
98+
* Just My Code stepping: when stepping, if framework code calls back to user code, automaticially stop.
99+
85100
#####Source File Map
86101
You can optionally configure a file by file mapping by providing map following this schema:
87102

0 commit comments

Comments
 (0)