Add a few extra features

This commit is contained in:
ItaloBorrelli 2025-04-11 14:33:21 -07:00
parent ac1591b035
commit 666d8cefce
6 changed files with 121 additions and 0 deletions

View File

@ -0,0 +1,22 @@
return {
"romgrk/barbar.nvim",
dependencies = {
"lewis6991/gitsigns.nvim", -- OPTIONAL: for git status
"nvim-tree/nvim-web-devicons", -- OPTIONAL: for file icons
},
keys = {
{ "<Tab>", "<cmd>BufferNext<cr>", desc = "next tab" },
{ "<S-Tab>", "<cmd>BufferPrevious<cr>", desc = "previous tab" },
{ "<leader>x", "<cmd>BufferClose<cr>", desc = "close tab" },
},
init = function()
vim.g.barbar_auto_setup = false
end,
config = function()
require("barbar").setup({
animation = true,
auto_hide = true,
clickable = true,
})
end,
}

View File

@ -0,0 +1,16 @@
return {
{
"stevearc/conform.nvim",
config = function()
require("conform").setup({
formatters_by_ft = {
lua = { "stylua" },
},
format_on_save = {
-- Enable or disable auto-formatting on save
lua = true,
},
})
end,
},
}

View File

@ -0,0 +1,44 @@
return {
{
"williamboman/mason.nvim",
dependencies = {
"williamboman/mason-lspconfig.nvim",
"WhoIsSethDaniel/mason-tool-installer.nvim",
},
config = function()
local mason = require("mason")
local mason_lspconfig = require("mason-lspconfig")
local mason_tool_installer = require("mason-tool-installer")
-- Enable mason and configure icons
mason.setup({
ui = {
icons = {
package_installed = "",
package_pending = "",
package_uninstalled = "",
},
},
})
-- Combine the setup for mason-lspconfig and mason-tool-installer
mason_lspconfig.setup({
ensure_installed = {
"cssls",
"dockerls",
"html",
"jsonls",
"lua_ls",
"vimls",
"yamlls",
},
})
mason_tool_installer.setup({
ensure_installed = {
"stylua",
},
})
end,
},
}

View File

@ -0,0 +1,12 @@
return {
"nvim-treesitter/nvim-treesitter",
config = function()
require("nvim-treesitter.configs").setup({
ensure_installed = {
"lua",
},
highlight = { enable = true },
indent = { enable = true },
})
end,
}

View File

@ -0,0 +1,9 @@
return {
"rebelot/kanagawa.nvim",
lazy = false, -- Ensure the plugin is loaded on startup
priority = 1000, -- Load this plugin first to apply the color scheme early
config = function()
-- Set the Kanagawa color scheme
vim.cmd("colorscheme kanagawa")
end,
}

View File

@ -0,0 +1,18 @@
return {
"folke/which-key.nvim",
event = "VeryLazy",
opts = {
-- your configuration comes here
-- or leave it empty to use the default settings
-- refer to the configuration section below
},
keys = {
{
"<leader>?",
function()
require("which-key").show({ global = false })
end,
desc = "Buffer Local Keymaps (which-key)",
},
},
}