Skip to content

Commit 0aaef4d

Browse files
s-kostyaevSergey Kostyaev
andauthored
Improve netcoredbg documentation (#509)
* improve netcoredbg install error messages * add netcoredbg docs Co-authored-by: Sergey Kostyaev <[email protected]>
1 parent 35112c7 commit 0aaef4d

File tree

2 files changed

+28
-9
lines changed

2 files changed

+28
-9
lines changed

dap-netcore.el

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -77,17 +77,19 @@ Will be set automatically in Emacs 27.1 or newer with libxml2 support."
7777
(lsp-download-install
7878
(lambda (&rest _)
7979
(shell-command unzip-script))
80-
(lambda (&rest _)
81-
(message "%s" "error during netcoredbg downloading"))
80+
(lambda (error &rest _)
81+
(user-error "Error during netcoredbg downloading: %s" error))
8282
:url dap-netcore-download-url
8383
:store-path temp-file)))
84-
(lsp-download-install
85-
(lambda (&rest _)
86-
(shell-command unzip-script))
87-
(lambda (&rest _)
88-
(message "%s" "error during netcoredbg downloading"))
89-
:url dap-netcore-download-url
90-
:store-path temp-file))))
84+
(if dap-netcore-download-url
85+
(lsp-download-install
86+
(lambda (&rest _)
87+
(shell-command unzip-script))
88+
(lambda (error &rest _)
89+
(user-error "Error during netcoredbg downloading: %s" error))
90+
:url dap-netcore-download-url
91+
:store-path temp-file)
92+
(user-error "`dap-netcore-download-url' is not set. You can customize it")))))
9193

9294
(defun dap-netcore--debugger-cmd ()
9395
"The location of the netcoredbg executable."

docs/page/configuration.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -438,3 +438,20 @@ To fully support rust and pretty printing of strings when debugging, remember to
438438

439439
Start debugging by selecting "Powershell: Launch Script" from
440440
`dap-debug` menu.
441+
442+
## Netcoredbg
443+
444+
[Netcoredbg](https://github.com/Samsung/netcoredbg) is debugger that supports C#, F# and probably other
445+
languages of Dotnet platform.
446+
447+
``` elisp
448+
(require 'dap-netcore)
449+
```
450+
451+
If you have Emacs 26 or older or if your Emacs built wilthout libxml2
452+
support you also need customize `dap-netcore-download-url`:
453+
454+
`M-x` `customize` `RET` `dap-netcore-download-url` `RET`
455+
456+
Start debugging by selecting ".Net Core Launch (Console)" or ".Net
457+
Core Attach (Console)" from `dap-debug` menu.

0 commit comments

Comments
 (0)