clean up nvim config

This commit is contained in:
2025-10-18 02:06:28 -03:00
parent 77dc9a8732
commit ffcadcce9b
7 changed files with 103 additions and 142 deletions

View File

@@ -1,9 +1,9 @@
{
"LuaSnip": { "branch": "master", "commit": "21e9fecfc07fb2cd707b6c7c3fa148550a34d053" },
"LuaSnip": { "branch": "master", "commit": "f958d9837c8fa7816bb8fb54977e658affc63c31" },
"cmp-nvim-lsp": { "branch": "main", "commit": "bd5a7d6db125d4654b50eeae9f5217f24bb22fd3" },
"cmp_luasnip": { "branch": "master", "commit": "98d9cb5c2c38532bd9bdb481067b20fea8f32e90" },
"lazy.nvim": { "branch": "main", "commit": "1ea3c4085785f460fb0e46d2fe1ee895f5f9e7c1" },
"lualine.nvim": { "branch": "master", "commit": "e533fac71bc361768f90004af695cd1f1aa1900a" },
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
"lualine.nvim": { "branch": "master", "commit": "3946f0122255bc377d14a59b27b609fb3ab25768" },
"monochrome.nvim": { "branch": "main", "commit": "2de78d9688ea4a177bcd9be554ab9192337d35ff" },
"nvim-autopairs": { "branch": "master", "commit": "7a2c97cccd60abc559344042fefb1d5a85b3e33b" },
"nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" },
@@ -17,6 +17,5 @@
"smear-cursor.nvim": { "branch": "main", "commit": "abfa5835920b1d76c0e24e1465a618ad914be90a" },
"telescope.nvim": { "branch": "master", "commit": "a0bbec21143c7bc5f8bb02e0005fa0b982edc026" },
"tokyodark.nvim": { "branch": "master", "commit": "cc70a2fb809d5376f2bd8e5836f9bb3f5fb8ef43" },
"tokyonight.nvim": { "branch": "main", "commit": "d14614cbfc63b6037bfccd48bb982d2ad2003352" },
"transparent.nvim": { "branch": "main", "commit": "8ac59883de84e9cd1850ea25cf087031c5ba7d54" }
}

View File

@@ -1,4 +1,3 @@
-- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
@@ -15,21 +14,15 @@ if not (vim.uv or vim.loop).fs_stat(lazypath) then
end
vim.opt.rtp:prepend(lazypath)
-- Make sure to setup `mapleader` and `maplocalleader` before
-- loading lazy.nvim so that mappings are correct.
-- This is also a good place to setup other settings (vim.opt)
vim.g.mapleader = " "
vim.g.maplocalleader = "\\"
-- Setup lazy.nvim
require("lazy").setup({
spec = {
-- import your plugins
{ import = "plugins" },
{ import = "plugins.coding" },
{ import = "plugins.colors" },
{ import = "plugins.ui" },
},
-- Configure any other settings here. See the documentation for more details.
-- colorscheme that will be used when installing plugins.
install = { colorscheme = { "habamax" } },
-- automatically check for plugin updates
checker = { enabled = true },
})

View File

@@ -1,127 +0,0 @@
return {
{
"sphamba/smear-cursor.nvim",
opts = {},
},
{
"xiyaowong/transparent.nvim",
lazy = false,
},
{
"folke/tokyonight.nvim",
lazy = false, -- make sure we load this during startup if it is your main colorscheme
priority = 1000, -- make sure to load this before all the other start plugins
config = function()
-- load the colorscheme here
-- vim.cmd([[colorscheme tokyonight]])
end,
},
{
"nyoom-engineering/oxocarbon.nvim",
lazy = false,
priority = 1001,
config = function()
--vim.opt.background = "light"
--vim.cmd([[colorscheme oxocarbon]])
end,
},
{
"tiagovla/tokyodark.nvim",
opts = {
-- custom options here
},
config = function(_, opts)
require("tokyodark").setup(opts) -- calling setup is optional
vim.cmd [[colorscheme tokyodark]]
end,
},
{
"kdheepak/monochrome.nvim",
lazy = false,
priority = 1002,
config = function()
-- vim.cmd([[colorscheme monochrome]])
end,
},
{
"nvim-treesitter/nvim-treesitter",
branch = 'master',
lazy = false,
build = ":TSUpdate",
},
{
"nvim-tree/nvim-tree.lua",
dependencies = { "nvim-tree/nvim-web-devicons" },
config = function()
require("nvim-tree").setup({
on_attach = function(bufnr)
local api = require("nvim-tree.api")
api.config.mappings.default_on_attach(bufnr)
vim.keymap.set('n', '<CR>', function()
local node = api.tree.get_node_under_cursor()
api.node.open.edit()
if not node or node.nodes == nil then
api.tree.close()
end
end, { buffer = bufnr, noremap = true, silent = true })
end,
})
vim.keymap.set("n", "<C-n>", ":NvimTreeToggle<CR>", { noremap = true, silent = true })
end,
},
{
"nvim-telescope/telescope.nvim",
tag = "0.1.8",
dependencies = { "nvim-lua/plenary.nvim" },
config = function()
local builtin = require('telescope.builtin')
vim.keymap.set("n", "<leader>f", builtin.find_files, { desc = "Telescope find files" })
end,
},
{
"nvim-lualine/lualine.nvim",
config = function()
require("lualine").setup()
end,
},
{
"windwp/nvim-autopairs",
config = function()
require("nvim-autopairs").setup()
end,
},
{
"neovim/nvim-lspconfig",
},
{
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"L3MON4D3/LuaSnip",
"saadparwaiz1/cmp_luasnip",
},
},
{
"rcarriga/nvim-notify",
config = function()
vim.notify = require("notify")
end,
}
}

View File

@@ -0,0 +1,34 @@
return {
{
"nvim-treesitter/nvim-treesitter",
branch = 'master',
lazy = false,
build = ":TSUpdate",
},
{
"nvim-telescope/telescope.nvim",
tag = "0.1.8",
dependencies = { "nvim-lua/plenary.nvim" },
config = function()
local builtin = require('telescope.builtin')
vim.keymap.set("n", "<leader>f", builtin.find_files, { desc = "Telescope find files" })
end,
},
{
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"L3MON4D3/LuaSnip",
"saadparwaiz1/cmp_luasnip",
},
},
{
"windwp/nvim-autopairs",
config = function()
require("nvim-autopairs").setup()
end,
},
{
"neovim/nvim-lspconfig",
},
}

View File

@@ -0,0 +1,16 @@
function theme(repo, opts)
opts = opts or {}
local theme = {
repo,
lazy = false,
}
return theme
end
return {
theme("nyoom-engineering/oxocarbon.nvim"),
theme("tiagovla/tokyodark.nvim"),
theme("kdheepak/monochrome.nvim"),
}

46
nvim/lua/plugins/ui.lua Normal file
View File

@@ -0,0 +1,46 @@
return {
{
"xiyaowong/transparent.nvim",
lazy = false,
},
{
"sphamba/smear-cursor.nvim",
opts = {},
},
{
"nvim-tree/nvim-tree.lua",
dependencies = { "nvim-tree/nvim-web-devicons" },
config = function()
require("nvim-tree").setup({
on_attach = function(bufnr)
local api = require("nvim-tree.api")
api.config.mappings.default_on_attach(bufnr)
vim.keymap.set('n', '<CR>', function()
local node = api.tree.get_node_under_cursor()
api.node.open.edit()
if not node or node.nodes == nil then
api.tree.close()
end
end, { buffer = bufnr, noremap = true, silent = true })
end,
})
vim.keymap.set("n", "<C-n>", ":NvimTreeToggle<CR>", { noremap = true, silent = true })
end,
},
{
"nvim-lualine/lualine.nvim",
config = function()
require("lualine").setup()
end,
},
{
"rcarriga/nvim-notify",
config = function()
vim.notify = require("notify")
end,
}
}