Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mfussenegger/nvim-lua-debugger
a Debug Adapter that allows debugging lua plugins written for Neovim
https://github.com/mfussenegger/nvim-lua-debugger
Last synced: about 1 month ago
JSON representation
a Debug Adapter that allows debugging lua plugins written for Neovim
- Host: GitHub
- URL: https://github.com/mfussenegger/nvim-lua-debugger
- Owner: mfussenegger
- Archived: true
- Created: 2020-09-02T17:28:13.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-04-07T15:14:40.000Z (over 3 years ago)
- Last Synced: 2024-05-22T18:32:03.683Z (4 months ago)
- Language: Lua
- Size: 6.84 KB
- Stars: 17
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# UNMAINTAINED
This was a prototype that never made it into a workable state.
There is now [lua-debug.nvim](https://github.com/jbyuki/lua-debug.nvim) which can be used instead.# Neovim Lua Debug Adapter
`nvim-lua-debugger` is a Debug Adapter that allows debugging lua plugins written for Neovim.
It is the server component in the [Debug Adapter Protocol][1].To use the debugger you'll need a client implementing the Debug Adapter Protocol:
- [vimspector][2]
- [nvim-dap][3]## MVP TODO
- [ ] initialization parts of the protocol
- [ ] setting breakpoints
- [ ] stopped event
- [ ] threads request handling
- [ ] stackTrace request handling
- [ ] scopes request handling
- [ ] variables request handling## Installation
- Requires [Neovim HEAD/nightly][4]
- nvim-lua-debugger is a plugin. Install it like any other Vim plugin.
- Call `:packadd nvim-lua-debugger` if you install `nvim-lua-debugger` to `'packpath'`.## Usage with nvim-dap
Add a new adapter entry:
```lua
local dap = require('dap')
dap.adapters.neovim = function(callback)
local server = require('lua_debugger').launch()
callback({ type = 'server'; host = server.host; port = server.port; })
end
```Add a new configuration entry:
```lua
local dap = require('dap')
dap.configurations.lua = {
{
type = 'neovim';
request = 'attach';
name = "Attach to running neovim instance";
},
}
```Then edit a ``lua`` file within Neovim and call `:lua require'dap'.continue()` to start debugging.
[1]: https://microsoft.github.io/debug-adapter-protocol/overview
[2]: https://github.com/puremourning/vimspector
[3]: https://github.com/mfussenegger/nvim-dap
[4]: https://github.com/neovim/neovim/releases/tag/nightly