Files
dotfiles/config/nvim/lua/plugins/init.lua
T
2026-05-09 07:31:53 +02:00

54 lines
1.8 KiB
Lua

vim.pack.add({
{ src = "https://github.com/ibhagwan/fzf-lua" },
{ src = "https://github.com/neovim/nvim-lspconfig" },
{ src = "https://github.com/romus204/tree-sitter-manager.nvim" },
{ src = "https://github.com/rebelot/kanagawa.nvim" },
{ src = "https://github.com/tribela/transparent.nvim" },
{ src = "https://github.com/nvim-lualine/lualine.nvim" }
})
vim.cmd(":colorscheme kanagawa")
require("tree-sitter-manager").setup({})
local theme = require('lualine.themes.kanagawa')
for _, mode in pairs(theme) do
if mode.b then mode.b.bg = '#16161D' end
if mode.c then mode.c.bg = '#16161D' end
if mode.x then mode.x.bg = '#16161D' end
if mode.y then mode.y.bg = '#16161D' end
if mode.z then mode.z.bg = '#16161D' end
end
require('lualine').setup({
options = {
theme = theme,
component_separators = '',
section_separators = '',
},
sections = {
lualine_a = {'mode'},
lualine_b = {},
lualine_c = {'filename'},
lualine_x = {'diagnostics'},
lualine_y = {},
lualine_z = {'lsp_status', 'location'},
},
})
require("fzf-lua").setup()
map("n", "<leader>f", ":lua FzfLua.files()<CR>")
map("n", "<leader>o", ":lua FzfLua.buffers()<CR>")
map("n", "<leader>h", ":lua FzfLua.help_tags()<CR>")
map("n", "<leader>d", ":lua FzfLua.diagnostics_document()<CR>")
map("n", "<leader>a", ":lua FzfLua.lsp_code_actions()<CR>")
map("n", "<leader>ss", ":lua FzfLua.grep_project()<CR>")
map("n", "<leader>sf", ":lua FzfLua.grep_curbuf()<CR>")
map("n", "<leader>sw", ":lua FzfLua.grep_cword()<CR>")
-- Lsp specific, uses nvim-lspconfigs with the below
vim.lsp.enable({ "gopls" })
map("n", "L", ":lua vim.diagnostic.open_float()<CR>")
map("n", "gd", ":lua vim.lsp.buf.definition()<CR>")
map("n", "<leader>r", ":lua vim.lsp.buf.rename()<CR>")