Another copy of my dotfiles. Because I don't completely trust GitHub.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.5 KiB

  1. local dap, dapui = require("dap"), require("dapui")
  2. -- Set breakpoint icon
  3. vim.fn.sign_define('DapBreakpoint', {text='', texthl='red', linehl='red', numhl='red'})
  4. -- Bind nvim-dap-ui to dap events
  5. dap.listeners.after.event_initialized["dapui_config"] = function()
  6. dapui.open()
  7. end
  8. dap.listeners.before.event_terminated["dapui_config"] = function()
  9. dapui.close()
  10. end
  11. dap.listeners.before.event_exited["dapui_config"] = function()
  12. dapui.close()
  13. end
  14. -- Python
  15. dap.adapters.python = {
  16. type = 'executable';
  17. command = 'python';
  18. args = { '-m', 'debugpy.adapter' };
  19. }
  20. dap.configurations.python = {
  21. {
  22. type = 'python';
  23. request = 'launch';
  24. name = "Launch file";
  25. program = "${file}";
  26. pythonPath = function()
  27. return '/usr/bin/python'
  28. end;
  29. },
  30. }
  31. dap.adapters.bashdb = {
  32. type = 'executable';
  33. command = vim.fn.stdpath("data") .. '/mason/packages/bash-debug-adapter/bash-debug-adapter';
  34. name = 'bashdb';
  35. }
  36. dap.configurations.sh = {
  37. {
  38. type = 'bashdb';
  39. request = 'launch';
  40. name = "Launch file";
  41. showDebugOutput = true;
  42. pathBashdb = vim.fn.stdpath("data") .. '/mason/packages/bash-debug-adapter/extension/bashdb_dir/bashdb';
  43. pathBashdbLib = vim.fn.stdpath("data") .. '/mason/packages/bash-debug-adapter/extension/bashdb_dir';
  44. trace = true;
  45. file = "${file}";
  46. program = "${file}";
  47. cwd = '${workspaceFolder}';
  48. pathCat = "cat";
  49. pathBash = "/bin/bash";
  50. pathMkfifo = "mkfifo";
  51. pathPkill = "pkill";
  52. args = {};
  53. env = {};
  54. terminalKind = "integrated";
  55. }
  56. }