#+title:    :tools debugger
#+subtitle: Step through code to add more bugs
#+created:  February 20, 2020
#+since:    2.0.0

* Description :unfold:
Turns Emacs into a debug adapter client, powered by [[doom-package:dape]]. The debug
adapter protocol aims to establish a standardized interface and API for
debuggers.

** Maintainers
/This module has no dedicated maintainers./ [[doom-contrib-maintainer:][Become a maintainer?]]

** Module flags
- +lsp ::
  *(This flag is deprecated)* Installs [[doom-package:dap-mode]] and
  [[doom-package:dap-ui]]. Requires [[doom-module::tools lsp]] (not compatible with
  Eglot).

** Packages
- [[doom-package:dape]]
- if [[doom-module:+lsp]]
  - [[doom-package:dap-mode]] 
  - [[doom-package:posframe]]

** Hacks
/No hacks documented for this module./

** TODO Changelog
# This section will be machine generated. Don't edit it by hand.
/This module does not have a changelog yet./

* Installation
[[id:01cffea4-3329-45e2-a892-95a384ab2338][Enable this module in your ~doom!~ block.]]

Then check out the [[https://github.com/svaante/dape?tab=readme-ov-file#supported-debug-adapters][install instructions for the debug adapters]] you want to work
with.

#+begin_quote
  Dape's documentation will instruct you to install debug adapters to
    =$EMACSDIR/debug-adapters/=, but Doom uses =$DOOMDIR/debug-adapters/= instead!
    Alter [[var:][dape-adapter-dir]] to change this.
#+end_quote

* Usage
Start the debugger with ~M-x +debugger/start~ (bound to [[kbd:][<leader> o d]]). You'll be
prompted to enter a debugger configuration to launch (use [[kbd:][<up>]]/[[kbd:][<down>]] to
traverse your history of debugger configs).

Once the session is started, it can be terminated by ~M-x +debugger/quit~.

* TODO Configuration
#+begin_quote
 󱌣 This module has no configuration documentation yet. [[doom-contrib-module:][Write some?]]
#+end_quote

The default debugger configs can be found in [[var:dape-configs]].

* Troubleshooting
/There are no known problems with this module./ [[doom-report:][Report one?]]

* Frequently asked questions
/This module has no FAQs yet./ [[doom-suggest-faq:][Ask one?]]

* TODO Appendix
#+begin_quote
 󱌣 This module has no appendix yet. [[doom-contrib-module:][Write one?]]
#+end_quote
