]> git.rmz.io Git - dotfiles.git/commitdiff
nvim: let rustaceanvim discover dap configs itself
authorSamir Benmendil <me@rmz.io>
Mon, 27 Oct 2025 22:36:31 +0000 (22:36 +0000)
committerSamir Benmendil <me@rmz.io>
Mon, 27 Oct 2025 22:38:45 +0000 (22:38 +0000)
nvim/lua/plugins/lang/rust.lua

index 97f9718041f6c00cf9f8ca16c4450fd0d3da8a1d..d57e565755550e1ef3b293758a1f7c03cbba2ac6 100644 (file)
@@ -79,25 +79,6 @@ return {
         },
       },
     },
-    config = function(_, opts)
-      local package_path = require("mason-registry").get_package("codelldb"):get_install_path()
-      local codelldb = package_path .. "/extension/adapter/codelldb"
-      local library_path = package_path .. "/extension/lldb/lib/liblldb.dylib"
-      local uname = io.popen("uname"):read("*l")
-      if uname == "Linux" then
-        library_path = package_path .. "/extension/lldb/lib/liblldb.so"
-      end
-      opts.dap = {
-        adapter = require("rustaceanvim.config").get_codelldb_adapter(codelldb, library_path),
-      }
-      vim.g.rustaceanvim = vim.tbl_deep_extend("keep", vim.g.rustaceanvim or {}, opts or {})
-      if vim.fn.executable("rust-analyzer") == 0 then
-        rmz.lazy.error(
-          "**rust-analyzer** not found in PATH, please install it.\nhttps://rust-analyzer.github.io/",
-          { title = "rustaceanvim" }
-        )
-      end
-    end,
   },
   { "neovim/nvim-lspconfig",
     opts = {