diff --git a/.config/nvim/lua/config/lazy.lua b/.config/nvim/lua/config/lazy.lua index f5ee74c..c381a4b 100644 --- a/.config/nvim/lua/config/lazy.lua +++ b/.config/nvim/lua/config/lazy.lua @@ -1,17 +1,17 @@ -- 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" - local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) - if vim.v.shell_error ~= 0 then - vim.api.nvim_echo({ - { "Failed to clone lazy.nvim:\n", "ErrorMsg" }, - { out, "WarningMsg" }, - { "\nPress any key to exit..." }, - }, true, {}) - vim.fn.getchar() - os.exit(1) - end + local lazyrepo = "https://github.com/folke/lazy.nvim.git" + local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) + if vim.v.shell_error ~= 0 then + vim.api.nvim_echo({ + { "Failed to clone lazy.nvim:\n", "ErrorMsg" }, + { out, "WarningMsg" }, + { "\nPress any key to exit..." }, + }, true, {}) + vim.fn.getchar() + os.exit(1) + end end vim.opt.rtp:prepend(lazypath) @@ -23,13 +23,13 @@ vim.g.maplocalleader = "\\" -- Setup lazy.nvim require("lazy").setup({ - spec = { - -- import your plugins - { import = "plugins" }, - }, - -- 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 }, + spec = { + -- import your plugins + { import = "plugins" }, + }, + -- 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 }, }) diff --git a/.config/nvim/lua/plugins/catppuccin.lua b/.config/nvim/lua/plugins/catppuccin.lua index 48bed69..dcfb655 100644 --- a/.config/nvim/lua/plugins/catppuccin.lua +++ b/.config/nvim/lua/plugins/catppuccin.lua @@ -1,5 +1,5 @@ return { - "catppuccin/nvim", - name = "catppuccin", - priority = 1000, + "catppuccin/nvim", + name = "catppuccin", + priority = 1000, } diff --git a/.config/nvim/lua/plugins/harpoon.lua b/.config/nvim/lua/plugins/harpoon.lua index c03e458..5a042ba 100644 --- a/.config/nvim/lua/plugins/harpoon.lua +++ b/.config/nvim/lua/plugins/harpoon.lua @@ -1,13 +1,13 @@ return { - "ThePrimeagen/harpoon", - branch = "harpoon2", - dependencies = { "nvim-lua/plenary.nvim" }, - config = function() - local harpoon = require("harpoon") + "ThePrimeagen/harpoon", + branch = "harpoon2", + dependencies = { "nvim-lua/plenary.nvim" }, + config = function() + local harpoon = require("harpoon") - -- REQUIRED - harpoon:setup() - -- REQUIRED + -- REQUIRED + harpoon:setup() + -- REQUIRED -- basic telescope configuration local conf = require("telescope.config").values @@ -17,27 +17,45 @@ return { table.insert(file_paths, item.value) end - require("telescope.pickers").new({}, { - prompt_title = "Harpoon", - finder = require("telescope.finders").new_table({ - results = file_paths, - }), - previewer = conf.file_previewer({}), - sorter = conf.generic_sorter({}), - }):find() + require("telescope.pickers") + .new({}, { + prompt_title = "Harpoon", + finder = require("telescope.finders").new_table({ + results = file_paths, + }), + previewer = conf.file_previewer({}), + sorter = conf.generic_sorter({}), + }) + :find() end - vim.keymap.set("n", "a", function() harpoon:list():add() end) - -- vim.keymap.set("n", "", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end) - vim.keymap.set("n", "", function() toggle_telescope(harpoon:list()) end, { desc = "Open harpoon window" }) + vim.keymap.set("n", "a", function() + harpoon:list():add() + end) + -- vim.keymap.set("n", "", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end) + vim.keymap.set("n", "", function() + toggle_telescope(harpoon:list()) + end, { desc = "Open harpoon window" }) - vim.keymap.set("n", "", function() harpoon:list():select(1) end) - vim.keymap.set("n", "", function() harpoon:list():select(2) end) - vim.keymap.set("n", "", function() harpoon:list():select(3) end) - vim.keymap.set("n", "", function() harpoon:list():select(4) end) + vim.keymap.set("n", "", function() + harpoon:list():select(1) + end) + vim.keymap.set("n", "", function() + harpoon:list():select(2) + end) + vim.keymap.set("n", "", function() + harpoon:list():select(3) + end) + vim.keymap.set("n", "", function() + harpoon:list():select(4) + end) - -- Toggle previous & next buffers stored within Harpoon list - vim.keymap.set("n", "", function() harpoon:list():prev() end) - vim.keymap.set("n", "", function() harpoon:list():next() end) - end, + -- Toggle previous & next buffers stored within Harpoon list + vim.keymap.set("n", "", function() + harpoon:list():prev() + end) + vim.keymap.set("n", "", function() + harpoon:list():next() + end) + end, } diff --git a/.config/nvim/lua/plugins/indent-blankline.lua b/.config/nvim/lua/plugins/indent-blankline.lua index 3502a46..753abde 100644 --- a/.config/nvim/lua/plugins/indent-blankline.lua +++ b/.config/nvim/lua/plugins/indent-blankline.lua @@ -1,6 +1,5 @@ return { "lukas-reineke/indent-blankline.nvim", main = "ibl", - opts = { - }, + opts = {}, } diff --git a/.config/nvim/lua/plugins/lint.lua b/.config/nvim/lua/plugins/lint.lua index 8f27495..8969b29 100644 --- a/.config/nvim/lua/plugins/lint.lua +++ b/.config/nvim/lua/plugins/lint.lua @@ -14,7 +14,7 @@ return { -- ruby = { "rubocop", "standardrb" }, ruby = { "standardrb" }, go = { "golangcilint" }, - } + } vim.api.nvim_create_autocmd({ "BufWritePost" }, { callback = function() diff --git a/.config/nvim/lua/plugins/lspconfig.lua b/.config/nvim/lua/plugins/lspconfig.lua index 58f30a2..7888f6b 100644 --- a/.config/nvim/lua/plugins/lspconfig.lua +++ b/.config/nvim/lua/plugins/lspconfig.lua @@ -1,65 +1,65 @@ return { - { - "williamboman/mason.nvim", - config = function() - require("mason").setup() - end, - }, - { - "williamboman/mason-lspconfig.nvim", - dependencies = { "williamboman/mason.nvim" }, - config = function() - require("mason-lspconfig").setup({ - ensure_installed = { - "lua_ls", - "ruby_lsp", - -- "standardrb", - "terraformls", - "yamlls", - "pyright", - "zls", - "gopls", - "bashls", - }, - }) - end, - }, - { - "neovim/nvim-lspconfig", - dependencies = { "williamboman/mason-lspconfig.nvim" }, - config = function() - local lspconfig = require("lspconfig") + { + "williamboman/mason.nvim", + config = function() + require("mason").setup() + end, + }, + { + "williamboman/mason-lspconfig.nvim", + dependencies = { "williamboman/mason.nvim" }, + config = function() + require("mason-lspconfig").setup({ + ensure_installed = { + "lua_ls", + "ruby_lsp", + -- "standardrb", + "terraformls", + "yamlls", + "pyright", + "zls", + "gopls", + "bashls", + }, + }) + end, + }, + { + "neovim/nvim-lspconfig", + dependencies = { "williamboman/mason-lspconfig.nvim" }, + config = function() + local lspconfig = require("lspconfig") - lspconfig.zls.setup({}) - lspconfig.ruby_lsp.setup({ - init_options = { - formatter = "standard", - linters = { "standard" }, - } - }) - -- lspconfig.standardrb.setup({}) - lspconfig.bashls.setup({}) - lspconfig.yamlls.setup({}) - lspconfig.terraformls.setup({}) - lspconfig.lua_ls.setup({ - settings = { - Lua = { - diagnostics = { - globals = { "vim" }, - }, - format = { - defaultConfig = { - indent_style = "tabs", - indent_size = "4", - }, - enable = true, - }, - }, - }, - }) - lspconfig.pyright.setup({}) - lspconfig.gopls.setup({}) - lspconfig.zls.setup({}) - end, - }, + lspconfig.zls.setup({}) + lspconfig.ruby_lsp.setup({ + init_options = { + formatter = "standard", + linters = { "standard" }, + }, + }) + -- lspconfig.standardrb.setup({}) + lspconfig.bashls.setup({}) + lspconfig.yamlls.setup({}) + lspconfig.terraformls.setup({}) + lspconfig.lua_ls.setup({ + settings = { + Lua = { + diagnostics = { + globals = { "vim" }, + }, + format = { + defaultConfig = { + indent_style = "tabs", + indent_size = "4", + }, + enable = true, + }, + }, + }, + }) + lspconfig.pyright.setup({}) + lspconfig.gopls.setup({}) + lspconfig.zls.setup({}) + end, + }, } diff --git a/.config/nvim/lua/plugins/nvim-tree.lua b/.config/nvim/lua/plugins/nvim-tree.lua index c071d5e..cd5cc57 100644 --- a/.config/nvim/lua/plugins/nvim-tree.lua +++ b/.config/nvim/lua/plugins/nvim-tree.lua @@ -1,6 +1,6 @@ return { - "nvim-tree/nvim-tree.lua", - config = function() - require("nvim-tree").setup() - end + "nvim-tree/nvim-tree.lua", + config = function() + require("nvim-tree").setup() + end, } diff --git a/.config/nvim/lua/plugins/zenbones.lua b/.config/nvim/lua/plugins/zenbones.lua index 7ef8154..554c29b 100644 --- a/.config/nvim/lua/plugins/zenbones.lua +++ b/.config/nvim/lua/plugins/zenbones.lua @@ -1,14 +1,14 @@ return { - "zenbones-theme/zenbones.nvim", - -- Optionally install Lush. Allows for more configuration or extending the colorscheme - -- If you don't want to install lush, make sure to set g:zenbones_compat = 1 - -- In Vim, compat mode is turned on as Lush only works in Neovim. - dependencies = "rktjmp/lush.nvim", - lazy = false, - priority = 1000, - -- you can set set configuration options here - -- config = function() - -- vim.g.zenbones_darken_comments = 45 - -- vim.cmd.colorscheme('zenbones') - -- end + "zenbones-theme/zenbones.nvim", + -- Optionally install Lush. Allows for more configuration or extending the colorscheme + -- If you don't want to install lush, make sure to set g:zenbones_compat = 1 + -- In Vim, compat mode is turned on as Lush only works in Neovim. + dependencies = "rktjmp/lush.nvim", + lazy = false, + priority = 1000, + -- you can set set configuration options here + -- config = function() + -- vim.g.zenbones_darken_comments = 45 + -- vim.cmd.colorscheme('zenbones') + -- end } diff --git a/.config/nvim/lua/vim-options.lua b/.config/nvim/lua/vim-options.lua index 2b4b55b..cff6849 100644 --- a/.config/nvim/lua/vim-options.lua +++ b/.config/nvim/lua/vim-options.lua @@ -5,6 +5,6 @@ vim.cmd("set shiftwidth=4") vim.cmd("set smartindent") vim.wo.number = true -vim.cmd.colorscheme "tokyonight" +vim.cmd.colorscheme("tokyonight") vim.opt.termguicolors = true