mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-21 08:35:48 +02:00
add: default rust analizer config
This commit is contained in:
parent
b2404fbb67
commit
22202bc11b
4 changed files with 41 additions and 11 deletions
|
@ -1,6 +1,36 @@
|
|||
local M = {}
|
||||
if pcode.active_rust_config then
|
||||
M = {
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = function(_, opts)
|
||||
opts.ensure_installed = opts.ensure_installed or {}
|
||||
vim.list_extend(opts.ensure_installed, { "rust" })
|
||||
end,
|
||||
},
|
||||
{
|
||||
"williamboman/mason-lspconfig.nvim",
|
||||
opts = function(_, opts)
|
||||
opts.skip_config = opts.skip_config or {}
|
||||
opts.ensure_installed = opts.ensure_installed or {}
|
||||
vim.list_extend(opts.ensure_installed, { "rust_analyzer" })
|
||||
vim.list_extend(opts.skip_config, { "rust_analyzer" })
|
||||
end,
|
||||
},
|
||||
{
|
||||
"stevearc/conform.nvim",
|
||||
event = "VeryLazy",
|
||||
opts = function(_, opts)
|
||||
local package = "ast-grep"
|
||||
require("user.utils.masoncfg").try_install(package)
|
||||
opts.formatters_by_ft.rust = { package }
|
||||
end,
|
||||
},
|
||||
-- disable none-ls
|
||||
{
|
||||
"nvimtools/none-ls.nvim",
|
||||
enabled = false,
|
||||
},
|
||||
{
|
||||
"rust-lang/rust.vim",
|
||||
ft = "rust",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue