diff options
author | Harald Eilertsen <haraldei@anduin.net> | 2024-09-04 13:57:48 +0200 |
---|---|---|
committer | Harald Eilertsen <haraldei@anduin.net> | 2024-09-04 13:57:48 +0200 |
commit | 0feb1c2bf8c62ba02834340bf1052e8fcafd531a (patch) | |
tree | b1b93a2d1e23136550073e4d414225a78596db2e | |
parent | 34ae1c4bc83ad3c2fe51b4b61d3f0c1508e0a003 (diff) | |
download | nvimrc-0feb1c2bf8c62ba02834340bf1052e8fcafd531a.tar.gz nvimrc-0feb1c2bf8c62ba02834340bf1052e8fcafd531a.tar.bz2 nvimrc-0feb1c2bf8c62ba02834340bf1052e8fcafd531a.zip |
Rust debugger support
-rw-r--r-- | lua/debugging.lua | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/lua/debugging.lua b/lua/debugging.lua index 82f073b..bb57624 100644 --- a/lua/debugging.lua +++ b/lua/debugging.lua @@ -18,6 +18,12 @@ dap.adapters.php = { args = { '/usr/lib/node_modules/php-debug/out/phpDebug.js' } } +dap.adapters.rust_gdb = { + type = "executable", + command = "rust-gdb", + args = { "-i", "dap" } +} + -- -- Configurations -- @@ -33,6 +39,18 @@ dap.configurations.c = { }, } +dap.configurations.rust = { + { + name = "Launch", + type = "rust_gdb", + request = "launch", + program = function() + return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/target/debug', 'file') + end, + cwd = "${workspacefolder}", + }, +} + dap.configurations.php = { { name = "Listen for Xdebug", |