mfussenegger / nvim-dap

Debug Adapter Protocol client implementation for Neovim
GNU General Public License v3.0
5.17k stars 180 forks source link

Add a new option dap.repl.show_tree: whether to show the tree in REPL #1001

Closed wookayin closed 10 months ago

wookayin commented 11 months ago

A new option show_tree can be set by users to configure whether to show the expandable tree in the DAP REPL window. Concise and simple representation in the REPL would be useful for many languages, see #737 for an example (python).

The option can be configured using, for instance:

require('dap.repl').show_tree = false

TODO: Add documentation in doc/dap.txt

wookayin commented 11 months ago

@mfussenegger Kindly bumping up and bringing this again to your attention.

mfussenegger commented 10 months ago

Thanks for the PR. I think having more options to control how the variables are displayed is something I want to add but this is rather limited and I'm not sure about the UI/UX.

I'll need to give this some more thought but I'm pretty sure it will be different than this, so I'm closing the PR

wookayin commented 10 months ago

Hope this or similar features can be implemented soon -- this is so essential for python debugging. I'm happy to discuss and contribute more.

wookayin commented 10 months ago

The reason I chose somewhat limited configuration like this is that nvim-dap doesn't have an universal configuration API, and previously we used to inject user configs into global variables (e.g. https://github.com/mfussenegger/nvim-dap/blob/master/doc/dap.txt#L564-L570, or injecting repl.commands.custtom_commands, etc.) We wouldn't need a UI for configuration.