mirror of
https://github.com/danbee/dotfiles-local
synced 2025-03-04 08:49:07 +00:00
Rejig config
This commit is contained in:
parent
b09c8ab204
commit
b5c9203263
@ -17,6 +17,7 @@ keymap(
|
|||||||
|
|
||||||
vim.api.nvim_create_autocmd("LspAttach", {
|
vim.api.nvim_create_autocmd("LspAttach", {
|
||||||
group = vim.api.nvim_create_augroup("UserLspConfig", {}),
|
group = vim.api.nvim_create_augroup("UserLspConfig", {}),
|
||||||
|
|
||||||
callback = function(ev)
|
callback = function(ev)
|
||||||
-- Enable completion triggered by <c-x><c-o>
|
-- Enable completion triggered by <c-x><c-o>
|
||||||
vim.bo[ev.buf].omnifunc = "v:lua.vim.lsp.omnifunc"
|
vim.bo[ev.buf].omnifunc = "v:lua.vim.lsp.omnifunc"
|
||||||
|
|||||||
7
config/nvim/lua/config/plugins/ascii.lua
Normal file
7
config/nvim/lua/config/plugins/ascii.lua
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
return {
|
||||||
|
"MaximilianLloyd/ascii.nvim",
|
||||||
|
|
||||||
|
dependencies = {
|
||||||
|
"MunifTanjim/nui.nvim",
|
||||||
|
},
|
||||||
|
}
|
||||||
@ -1,24 +1,30 @@
|
|||||||
return function()
|
return {
|
||||||
require("dashboard").setup({
|
"glepnir/dashboard-nvim",
|
||||||
theme = "hyper",
|
|
||||||
config = {
|
event = "VimEnter",
|
||||||
header = {
|
|
||||||
[[ . . ]],
|
config = function()
|
||||||
[[ ';;,. ::' ]],
|
require("dashboard").setup({
|
||||||
[[ ,:::;,, :ccc, ]],
|
theme = "hyper",
|
||||||
[[,::c::,,,,. :cccc,]],
|
config = {
|
||||||
[[,cccc:;;;;;. cllll,]],
|
header = {
|
||||||
[[,cccc;.;;;;;, cllll;]],
|
[[ . . ]],
|
||||||
[[:cccc; .;;;;;;. coooo;]],
|
[[ ';;,. ::' ]],
|
||||||
[[;llll; ,:::::'loooo;]],
|
[[ ,:::;,, :ccc, ]],
|
||||||
[[;llll: ':::::loooo:]],
|
[[,::c::,,,,. :cccc,]],
|
||||||
[[:oooo: .::::llodd:]],
|
[[,cccc:;;;;;. cllll,]],
|
||||||
[[.;ooo: ;cclooo:.]],
|
[[,cccc;.;;;;;, cllll;]],
|
||||||
[[ .;oc 'coo;. ]],
|
[[:cccc; .;;;;;;. coooo;]],
|
||||||
[[ .' .,. ]],
|
[[;llll; ,:::::'loooo;]],
|
||||||
[[]],
|
[[;llll: ':::::loooo:]],
|
||||||
[[]],
|
[[:oooo: .::::llodd:]],
|
||||||
|
[[.;ooo: ;cclooo:.]],
|
||||||
|
[[ .;oc 'coo;. ]],
|
||||||
|
[[ .' .,. ]],
|
||||||
|
[[]],
|
||||||
|
[[]],
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
})
|
||||||
})
|
end,
|
||||||
end
|
}
|
||||||
|
|||||||
7
config/nvim/lua/config/plugins/gitsigns.lua
Normal file
7
config/nvim/lua/config/plugins/gitsigns.lua
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
return {
|
||||||
|
"lewis6991/gitsigns.nvim",
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("gitsigns").setup()
|
||||||
|
end,
|
||||||
|
}
|
||||||
@ -1,8 +1,12 @@
|
|||||||
return function()
|
return {
|
||||||
require("config.plugins.lspconfig.elixir")
|
"neovim/nvim-lspconfig",
|
||||||
require("config.plugins.lspconfig.emmet")
|
|
||||||
require("config.plugins.lspconfig.javascript")
|
config = function()
|
||||||
require("config.plugins.lspconfig.lua")
|
require("config.plugins.lspconfig.elixir")
|
||||||
require("config.plugins.lspconfig.ruby")
|
require("config.plugins.lspconfig.emmet")
|
||||||
require("config.plugins.lspconfig.rust")
|
require("config.plugins.lspconfig.javascript")
|
||||||
end
|
require("config.plugins.lspconfig.lua")
|
||||||
|
require("config.plugins.lspconfig.ruby")
|
||||||
|
require("config.plugins.lspconfig.rust")
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@ -1,3 +1,9 @@
|
|||||||
return function()
|
return {
|
||||||
require("lualine").setup()
|
"nvim-lualine/lualine.nvim",
|
||||||
end
|
|
||||||
|
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("lualine").setup()
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
7
config/nvim/lua/config/plugins/mason.lua
Normal file
7
config/nvim/lua/config/plugins/mason.lua
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
return {
|
||||||
|
"williamboman/mason.nvim",
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("mason").setup()
|
||||||
|
end,
|
||||||
|
}
|
||||||
@ -1,8 +1,18 @@
|
|||||||
return function()
|
return {
|
||||||
-- Unless you are still migrating, remove the deprecated commands from v1.x
|
"nvim-neo-tree/neo-tree.nvim",
|
||||||
vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]])
|
|
||||||
|
|
||||||
require("neo-tree").setup({
|
dependencies = {
|
||||||
hijack_netrw_behavior = "open_default",
|
"nvim-lua/plenary.nvim",
|
||||||
})
|
"nvim-tree/nvim-web-devicons",
|
||||||
end
|
"MunifTanjim/nui.nvim",
|
||||||
|
},
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
-- Unless you are still migrating, remove the deprecated commands from v1.x
|
||||||
|
vim.cmd([[ let g:neo_tree_remove_legacy_commands = 1 ]])
|
||||||
|
|
||||||
|
require("neo-tree").setup({
|
||||||
|
hijack_netrw_behavior = "open_default",
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@ -1,39 +1,45 @@
|
|||||||
return function()
|
return {
|
||||||
local null_ls = require("null-ls")
|
"jose-elias-alvarez/null-ls.nvim",
|
||||||
|
|
||||||
null_ls.setup({
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
sources = {
|
|
||||||
null_ls.builtins.formatting.crystal_format,
|
|
||||||
null_ls.builtins.formatting.prettierd.with({
|
|
||||||
filetypes = {
|
|
||||||
"css",
|
|
||||||
"graphql",
|
|
||||||
"handlebars",
|
|
||||||
"html",
|
|
||||||
"javascript",
|
|
||||||
"javascriptreact",
|
|
||||||
"json",
|
|
||||||
"jsonc",
|
|
||||||
"less",
|
|
||||||
"markdown",
|
|
||||||
"markdown.mdx",
|
|
||||||
"ruby",
|
|
||||||
"scss",
|
|
||||||
"typescript",
|
|
||||||
"typescriptreact",
|
|
||||||
"vue",
|
|
||||||
"yaml",
|
|
||||||
},
|
|
||||||
timeout = 5000,
|
|
||||||
}),
|
|
||||||
null_ls.builtins.formatting.rustfmt,
|
|
||||||
null_ls.builtins.formatting.standardrb,
|
|
||||||
null_ls.builtins.formatting.stylua,
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Format on save
|
config = function()
|
||||||
vim.api.nvim_create_autocmd("BufWritePre", {
|
local null_ls = require("null-ls")
|
||||||
command = "lua vim.lsp.buf.format()",
|
|
||||||
})
|
null_ls.setup({
|
||||||
end
|
sources = {
|
||||||
|
null_ls.builtins.formatting.crystal_format,
|
||||||
|
null_ls.builtins.formatting.prettierd.with({
|
||||||
|
filetypes = {
|
||||||
|
"css",
|
||||||
|
"graphql",
|
||||||
|
"handlebars",
|
||||||
|
"html",
|
||||||
|
"javascript",
|
||||||
|
"javascriptreact",
|
||||||
|
"json",
|
||||||
|
"jsonc",
|
||||||
|
"less",
|
||||||
|
"markdown",
|
||||||
|
"markdown.mdx",
|
||||||
|
"ruby",
|
||||||
|
"scss",
|
||||||
|
"typescript",
|
||||||
|
"typescriptreact",
|
||||||
|
"vue",
|
||||||
|
"yaml",
|
||||||
|
},
|
||||||
|
timeout = 5000,
|
||||||
|
}),
|
||||||
|
null_ls.builtins.formatting.rustfmt,
|
||||||
|
null_ls.builtins.formatting.standardrb,
|
||||||
|
null_ls.builtins.formatting.stylua,
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Format on save
|
||||||
|
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||||
|
command = "lua vim.lsp.buf.format()",
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@ -1,54 +1,66 @@
|
|||||||
local has_words_before = function()
|
local has_words_before = function()
|
||||||
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
|
local line, col = unpack(vim.api.nvim_win_get_cursor(0))
|
||||||
return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil
|
return col ~= 0
|
||||||
|
and vim.api
|
||||||
|
.nvim_buf_get_lines(0, line - 1, line, true)[1]
|
||||||
|
:sub(col, col)
|
||||||
|
:match("%s")
|
||||||
|
== nil
|
||||||
end
|
end
|
||||||
|
|
||||||
local feedkey = function(key, mode)
|
local feedkey = function(key, mode)
|
||||||
vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes(key, true, true, true), mode, true)
|
vim.api.nvim_feedkeys(
|
||||||
|
vim.api.nvim_replace_termcodes(key, true, true, true),
|
||||||
|
mode,
|
||||||
|
true
|
||||||
|
)
|
||||||
end
|
end
|
||||||
|
|
||||||
return function()
|
return {
|
||||||
local cmp = require("cmp")
|
"hrsh7th/nvim-cmp",
|
||||||
|
config = function()
|
||||||
|
local cmp = require("cmp")
|
||||||
|
|
||||||
cmp.setup({
|
cmp.setup({
|
||||||
snippet = {
|
snippet = {
|
||||||
expand = function(args)
|
expand = function(args)
|
||||||
vim.fn["vsnip#anonymous"](args.body)
|
vim.fn["vsnip#anonymous"](args.body)
|
||||||
end,
|
end,
|
||||||
},
|
},
|
||||||
window = {
|
window = {
|
||||||
-- completion = cmp.config.window.bordered(),
|
-- completion = cmp.config.window.bordered(),
|
||||||
-- documentation = cmp.config.window.bordered(),
|
-- documentation = cmp.config.window.bordered(),
|
||||||
},
|
},
|
||||||
mapping = cmp.mapping.preset.insert({
|
mapping = cmp.mapping.preset.insert({
|
||||||
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
["<C-b>"] = cmp.mapping.scroll_docs(-4),
|
||||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||||
["<C-Space>"] = cmp.mapping.complete(),
|
["<C-Space>"] = cmp.mapping.complete(),
|
||||||
["<C-e>"] = cmp.mapping.abort(),
|
["<C-e>"] = cmp.mapping.abort(),
|
||||||
["<Tab>"] = cmp.mapping(function(fallback)
|
["<Tab>"] = cmp.mapping(function(fallback)
|
||||||
if cmp.visible() then
|
if cmp.visible() then
|
||||||
cmp.select_next_item()
|
cmp.select_next_item()
|
||||||
elseif vim.fn["vsnip#available"](1) == 1 then
|
elseif vim.fn["vsnip#available"](1) == 1 then
|
||||||
feedkey("<Plug>(vsnip-expand-or-jump)", "")
|
feedkey("<Plug>(vsnip-expand-or-jump)", "")
|
||||||
elseif has_words_before() then
|
elseif has_words_before() then
|
||||||
cmp.complete()
|
cmp.complete()
|
||||||
else
|
else
|
||||||
fallback()
|
fallback()
|
||||||
end
|
end
|
||||||
end, { "i", "s" }),
|
end, { "i", "s" }),
|
||||||
["<S-Tab>"] = cmp.mapping(function()
|
["<S-Tab>"] = cmp.mapping(function()
|
||||||
if cmp.visible() then
|
if cmp.visible() then
|
||||||
cmp.select_prev_item()
|
cmp.select_prev_item()
|
||||||
elseif vim.fn["vsnip#jumpable"](-1) == 1 then
|
elseif vim.fn["vsnip#jumpable"](-1) == 1 then
|
||||||
feedkey("<Plug>(vsnip-jump-prev)", "")
|
feedkey("<Plug>(vsnip-jump-prev)", "")
|
||||||
end
|
end
|
||||||
end, { "i", "s" })
|
end, { "i", "s" }),
|
||||||
}),
|
}),
|
||||||
sources = cmp.config.sources({
|
sources = cmp.config.sources({
|
||||||
{ name = "nvim_lsp" },
|
{ name = "nvim_lsp" },
|
||||||
{ name = "vsnip" },
|
{ name = "vsnip" },
|
||||||
}, {
|
}, {
|
||||||
{ name = "buffer" },
|
{ name = "buffer" },
|
||||||
}),
|
}),
|
||||||
})
|
})
|
||||||
end
|
end,
|
||||||
|
}
|
||||||
|
|||||||
7
config/nvim/lua/config/plugins/nvim-test.lua
Normal file
7
config/nvim/lua/config/plugins/nvim-test.lua
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
return {
|
||||||
|
"klen/nvim-test",
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("nvim-test").setup()
|
||||||
|
end,
|
||||||
|
}
|
||||||
82
config/nvim/lua/config/plugins/nvim-treesitter.lua
Normal file
82
config/nvim/lua/config/plugins/nvim-treesitter.lua
Normal file
@ -0,0 +1,82 @@
|
|||||||
|
return {
|
||||||
|
{
|
||||||
|
"nvim-treesitter/nvim-treesitter",
|
||||||
|
|
||||||
|
build = ":TSUpdate",
|
||||||
|
|
||||||
|
event = { "BufReadPost", "BufNewFile" },
|
||||||
|
|
||||||
|
dependencies = {
|
||||||
|
{
|
||||||
|
"nvim-treesitter/nvim-treesitter-textobjects",
|
||||||
|
init = function()
|
||||||
|
-- PERF: no need to load the plugin,
|
||||||
|
-- if we only need its queries for mini.ai
|
||||||
|
local plugin =
|
||||||
|
require("lazy.core.config").spec.plugins["nvim-treesitter"]
|
||||||
|
local opts = require("lazy.core.plugin").values(plugin, "opts", false)
|
||||||
|
local enabled = false
|
||||||
|
|
||||||
|
if opts.textobjects then
|
||||||
|
for _, mod in ipairs({ "move", "select", "swap", "lsp_interop" }) do
|
||||||
|
if opts.textobjects[mod] and opts.textobjects[mod].enable then
|
||||||
|
enabled = true
|
||||||
|
break
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if not enabled then
|
||||||
|
require("lazy.core.loader").disable_rtp_plugin(
|
||||||
|
"nvim-treesitter-textobjects"
|
||||||
|
)
|
||||||
|
end
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
"JoosepAlviste/nvim-ts-context-commentstring",
|
||||||
|
"RRethy/nvim-treesitter-endwise",
|
||||||
|
},
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("nvim-treesitter.configs").setup({
|
||||||
|
highlight = { enable = true },
|
||||||
|
indent = { enable = true },
|
||||||
|
endwise = { enable = true },
|
||||||
|
context_commentstring = { enable = true },
|
||||||
|
auto_install = true,
|
||||||
|
sync_install = false,
|
||||||
|
ensure_installed = {
|
||||||
|
"bash",
|
||||||
|
"c",
|
||||||
|
"comment",
|
||||||
|
"css",
|
||||||
|
"dockerfile",
|
||||||
|
"eex",
|
||||||
|
"elixir",
|
||||||
|
"html",
|
||||||
|
"javascript",
|
||||||
|
"json",
|
||||||
|
"lua",
|
||||||
|
"luadoc",
|
||||||
|
"luap",
|
||||||
|
"markdown",
|
||||||
|
"markdown_inline",
|
||||||
|
"python",
|
||||||
|
"query",
|
||||||
|
"regex",
|
||||||
|
"ruby",
|
||||||
|
"rust",
|
||||||
|
"scss",
|
||||||
|
"sql",
|
||||||
|
"swift",
|
||||||
|
"toml",
|
||||||
|
"tsx",
|
||||||
|
"typescript",
|
||||||
|
"vim",
|
||||||
|
"vue",
|
||||||
|
"yaml",
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
}
|
||||||
5
config/nvim/lua/config/plugins/telescope.lua
Normal file
5
config/nvim/lua/config/plugins/telescope.lua
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
return {
|
||||||
|
"nvim-telescope/telescope.nvim",
|
||||||
|
|
||||||
|
dependencies = { "nvim-lua/plenary.nvim" },
|
||||||
|
}
|
||||||
@ -1,41 +0,0 @@
|
|||||||
return function()
|
|
||||||
require("nvim-treesitter.configs").setup({
|
|
||||||
highlight = { enable = true },
|
|
||||||
indent = { enable = true },
|
|
||||||
endwise = { enable = true },
|
|
||||||
context_commentstring = { enable = true },
|
|
||||||
auto_install = true,
|
|
||||||
sync_install = false,
|
|
||||||
ensure_installed = {
|
|
||||||
"bash",
|
|
||||||
"c",
|
|
||||||
"comment",
|
|
||||||
"css",
|
|
||||||
"dockerfile",
|
|
||||||
"eex",
|
|
||||||
"elixir",
|
|
||||||
"html",
|
|
||||||
"javascript",
|
|
||||||
"json",
|
|
||||||
"lua",
|
|
||||||
"luadoc",
|
|
||||||
"luap",
|
|
||||||
"markdown",
|
|
||||||
"markdown_inline",
|
|
||||||
"python",
|
|
||||||
"query",
|
|
||||||
"regex",
|
|
||||||
"ruby",
|
|
||||||
"rust",
|
|
||||||
"scss",
|
|
||||||
"sql",
|
|
||||||
"swift",
|
|
||||||
"toml",
|
|
||||||
"tsx",
|
|
||||||
"typescript",
|
|
||||||
"vim",
|
|
||||||
"vue",
|
|
||||||
"yaml",
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end
|
|
||||||
@ -1,3 +1,9 @@
|
|||||||
return function()
|
return {
|
||||||
require("treesj").setup()
|
"Wansmer/treesj",
|
||||||
end
|
|
||||||
|
dependencies = { "nvim-treesitter/nvim-treesitter" },
|
||||||
|
|
||||||
|
config = function()
|
||||||
|
require("treesj").setup()
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@ -1,10 +1,14 @@
|
|||||||
return function()
|
return {
|
||||||
vim.o.timeout = true
|
"folke/which-key.nvim",
|
||||||
vim.o.timeoutlen = 300
|
|
||||||
|
|
||||||
require("which-key").setup({
|
config = function()
|
||||||
-- your configuration comes here
|
vim.o.timeout = true
|
||||||
-- or leave it empty to use the default settings
|
vim.o.timeoutlen = 300
|
||||||
-- refer to the configuration section below
|
|
||||||
})
|
require("which-key").setup({
|
||||||
end
|
-- your configuration comes here
|
||||||
|
-- or leave it empty to use the default settings
|
||||||
|
-- refer to the configuration section below
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
|||||||
@ -1,74 +1,24 @@
|
|||||||
return {
|
return {
|
||||||
"hrsh7th/cmp-nvim-lsp",
|
|
||||||
"hrsh7th/cmp-buffer",
|
"hrsh7th/cmp-buffer",
|
||||||
"hrsh7th/cmp-path",
|
|
||||||
"hrsh7th/cmp-cmdline",
|
"hrsh7th/cmp-cmdline",
|
||||||
|
"hrsh7th/cmp-nvim-lsp",
|
||||||
|
"hrsh7th/cmp-path",
|
||||||
"hrsh7th/cmp-vsnip",
|
"hrsh7th/cmp-vsnip",
|
||||||
"hrsh7th/vim-vsnip",
|
"hrsh7th/vim-vsnip",
|
||||||
"tpope/vim-fugitive",
|
|
||||||
"preservim/nerdcommenter",
|
"preservim/nerdcommenter",
|
||||||
{
|
"tpope/vim-fugitive",
|
||||||
"Wansmer/treesj",
|
require("config.plugins.ascii"),
|
||||||
dependencies = { "nvim-treesitter/nvim-treesitter" },
|
require("config.plugins.dashboard"),
|
||||||
config = require("config.plugins.treesj"),
|
require("config.plugins.gitsigns"),
|
||||||
},
|
require("config.plugins.lspconfig"),
|
||||||
{
|
require("config.plugins.lualine"),
|
||||||
"MaximilianLloyd/ascii.nvim",
|
require("config.plugins.mason"),
|
||||||
dependencies = {
|
require("config.plugins.neo-tree"),
|
||||||
"MunifTanjim/nui.nvim",
|
require("config.plugins.null-ls"),
|
||||||
},
|
require("config.plugins.nvim-cmp"),
|
||||||
},
|
require("config.plugins.nvim-test"),
|
||||||
{
|
require("config.plugins.nvim-treesitter"),
|
||||||
"glepnir/dashboard-nvim",
|
require("config.plugins.telescope"),
|
||||||
event = "VimEnter",
|
require("config.plugins.treesj"),
|
||||||
config = require("config.plugins.dashboard"),
|
require("config.plugins.which-key"),
|
||||||
dependencies = { { "nvim-tree/nvim-web-devicons" } },
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"lewis6991/gitsigns.nvim",
|
|
||||||
config = function()
|
|
||||||
require("gitsigns").setup()
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"hrsh7th/nvim-cmp",
|
|
||||||
config = require("config.plugins.nvim-cmp"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"williamboman/mason.nvim",
|
|
||||||
config = function()
|
|
||||||
require("mason").setup()
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"neovim/nvim-lspconfig",
|
|
||||||
config = require("config.plugins.lspconfig"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"nvim-lualine/lualine.nvim",
|
|
||||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
|
||||||
config = require("config.plugins.lualine"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"nvim-neo-tree/neo-tree.nvim",
|
|
||||||
dependencies = {
|
|
||||||
"nvim-lua/plenary.nvim",
|
|
||||||
"nvim-tree/nvim-web-devicons",
|
|
||||||
"MunifTanjim/nui.nvim",
|
|
||||||
},
|
|
||||||
config = require("config.plugins.neo-tree"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"nvim-telescope/telescope.nvim",
|
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"folke/which-key.nvim",
|
|
||||||
config = require("config.plugins.which-key"),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"jose-elias-alvarez/null-ls.nvim",
|
|
||||||
dependencies = { "nvim-lua/plenary.nvim" },
|
|
||||||
config = require("config.plugins.null-ls"),
|
|
||||||
},
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,35 +0,0 @@
|
|||||||
return {
|
|
||||||
{
|
|
||||||
"nvim-treesitter/nvim-treesitter",
|
|
||||||
build = ":TSUpdate",
|
|
||||||
event = { "BufReadPost", "BufNewFile" },
|
|
||||||
dependencies = {
|
|
||||||
{
|
|
||||||
"nvim-treesitter/nvim-treesitter-textobjects",
|
|
||||||
init = function()
|
|
||||||
-- PERF: no need to load the plugin, if we only need its queries for mini.ai
|
|
||||||
local plugin =
|
|
||||||
require("lazy.core.config").spec.plugins["nvim-treesitter"]
|
|
||||||
local opts = require("lazy.core.plugin").values(plugin, "opts", false)
|
|
||||||
local enabled = false
|
|
||||||
if opts.textobjects then
|
|
||||||
for _, mod in ipairs({ "move", "select", "swap", "lsp_interop" }) do
|
|
||||||
if opts.textobjects[mod] and opts.textobjects[mod].enable then
|
|
||||||
enabled = true
|
|
||||||
break
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
if not enabled then
|
|
||||||
require("lazy.core.loader").disable_rtp_plugin(
|
|
||||||
"nvim-treesitter-textobjects"
|
|
||||||
)
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
"JoosepAlviste/nvim-ts-context-commentstring",
|
|
||||||
"RRethy/nvim-treesitter-endwise",
|
|
||||||
},
|
|
||||||
config = require("config.plugins.tree-sitter"),
|
|
||||||
},
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue
Block a user