From 1fd0af14d592d612c2aaab7717c04c8806ba3daa Mon Sep 17 00:00:00 2001 From: Elvis Claros Castro Date: Thu, 11 Jul 2024 05:12:18 -0300 Subject: Feat: Todo actulizado --- lua/alpha/dap/configs/elixir.lua | 52 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 lua/alpha/dap/configs/elixir.lua (limited to 'lua/alpha/dap/configs/elixir.lua') diff --git a/lua/alpha/dap/configs/elixir.lua b/lua/alpha/dap/configs/elixir.lua new file mode 100644 index 0000000..bf732ce --- /dev/null +++ b/lua/alpha/dap/configs/elixir.lua @@ -0,0 +1,52 @@ +local dap = require('dap') + +dap.adapters.mix_task = { + type = 'executable', + command = 'elixir-ls-debugger', -- El comando 'elixir-ls' está en $PATH + args = {} +} + +dap.configurations.elixir = { + { + type = "mix_task", + name = "mix (Default task)", + request = "launch", + projectDir = "${workspaceRoot}" + }, + { + type = "mix_task", + name = "mix test", + request = "launch", + task = 'test', + env = { + MIX_ENV = "test", + MIX_TARGET = "host", + HEX_UNSAFE_HTTPS = 1 + }, + taskArgs = {"--trace"}, + startApps = true, -- for Phoenix projects + projectDir = "${workspaceFolder}", + requireFiles = { + "test/**/test_helper.exs", + "test/**/*_test.exs" + } + }, + { + type = "mix_task", + name = "phx server", + request = "launch", + stackTraceMode = "all", + task = 'phx.server', + debugAutoInterpretAllModules = true, + noDebug = false, + exitAfterTaskReturns = false, + env = { + MIX_ENV = "dev", + MIX_TARGET = "host", + HEX_UNSAFE_HTTPS = 1 + }, + startApps = false, -- for Phoenix projects + taskArgs = {"--no-halt", "--open"}, + projectDir = "${workspaceFolder}", + }, +} -- cgit v1.2.3