mirror of
https://github.com/tuxdotrs/tawm.git
synced 2025-07-06 13:06:35 +05:30
add rust and golang with debugger
This commit is contained in:
@ -16,6 +16,7 @@ local options = {
|
||||
markdown = { prettier },
|
||||
nix = { "alejandra" },
|
||||
go = { "goimports", "gofumpt" },
|
||||
rust = { "rust_analyzer" },
|
||||
},
|
||||
|
||||
format_on_save = {
|
||||
|
16
pkgs/nvchad/nvim/lua/configs/dap.lua
Normal file
16
pkgs/nvchad/nvim/lua/configs/dap.lua
Normal file
@ -0,0 +1,16 @@
|
||||
require("dapui").setup()
|
||||
|
||||
local dap, dapui = require("dap"), require("dapui")
|
||||
|
||||
dap.listeners.before.attach.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.launch.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.event_terminated.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
dap.listeners.before.event_exited.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
5
pkgs/nvchad/nvim/lua/configs/go.lua
Normal file
5
pkgs/nvchad/nvim/lua/configs/go.lua
Normal file
@ -0,0 +1,5 @@
|
||||
require("go").setup({
|
||||
trouble = true,
|
||||
icons = { breakpoint = "", currentpos = "" },
|
||||
gocoverage_sign = "│",
|
||||
})
|
@ -21,6 +21,9 @@ M.treesitter = {
|
||||
"gomod",
|
||||
"gowork",
|
||||
"gosum",
|
||||
|
||||
-- rust
|
||||
"rust",
|
||||
},
|
||||
}
|
||||
|
||||
@ -44,13 +47,9 @@ M.mason = {
|
||||
|
||||
-- go
|
||||
"gopls",
|
||||
"goimports",
|
||||
"gofumpt",
|
||||
"gomodifytags",
|
||||
"impl",
|
||||
"iferr",
|
||||
"staticcheck",
|
||||
"delve",
|
||||
|
||||
-- rust
|
||||
"codelldb",
|
||||
},
|
||||
}
|
||||
|
||||
|
17
pkgs/nvchad/nvim/lua/configs/rust.lua
Normal file
17
pkgs/nvchad/nvim/lua/configs/rust.lua
Normal file
@ -0,0 +1,17 @@
|
||||
local configs = require("nvchad.configs.lspconfig")
|
||||
local on_attach = configs.on_attach
|
||||
local capabilities = configs.capabilities
|
||||
|
||||
vim.g.rustaceanvim = {
|
||||
server = {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
default_settings = {
|
||||
["rust-analyzer"] = {
|
||||
cargo = {
|
||||
allFeatures = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
Reference in New Issue
Block a user