diff --git a/nvim/lazy-lock.json b/nvim/lazy-lock.json index 5a1b478..1642ff2 100644 --- a/nvim/lazy-lock.json +++ b/nvim/lazy-lock.json @@ -1,17 +1,18 @@ { "LuaSnip": { "branch": "master", "commit": "03c8e67eb7293c404845b3982db895d59c0d1538" }, "base16-vim": { "branch": "master", "commit": "3be3cd82cd31acfcab9a41bad853d9c68d30478d" }, + "bufferline.nvim": { "branch": "main", "commit": "0b2fd861eee7595015b6561dade52fb060be10c4" }, "gitsigns.nvim": { "branch": "main", "commit": "562dc47189ad3c8696dbf460d38603a74d544849" }, "indent-blankline.nvim": { "branch": "master", "commit": "db926997af951da38e5004ec7b9fbdc480b48f5d" }, "lazy.nvim": { "branch": "main", "commit": "077102c5bfc578693f12377846d427f49bc50076" }, "lualine.nvim": { "branch": "master", "commit": "b431d228b7bbcdaea818bdc3e25b8cdbe861f056" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "1c55991321d1a861537e32446affc5de5d9a6eaf" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "482350b050bd413931c2cdd4857443c3da7d57cb" }, "mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" }, "neo-tree.nvim": { "branch": "main", "commit": "206241e451c12f78969ff5ae53af45616ffc9b72" }, "nui.nvim": { "branch": "main", "commit": "61574ce6e60c815b0a0c4b5655b8486ba58089a1" }, "nvim-cmp": { "branch": "main", "commit": "ae644feb7b67bf1ce4260c231d1d4300b19c6f30" }, - "nvim-lspconfig": { "branch": "master", "commit": "dddd0945c0f31a0abd843425927a1712d2db2e10" }, - "nvim-treesitter": { "branch": "master", "commit": "6699eae8ba4551fe927da0f0f3f61ae085f836aa" }, + "nvim-lspconfig": { "branch": "master", "commit": "b21c166bbf337734f2a39734a905c1c3e298205c" }, + "nvim-treesitter": { "branch": "master", "commit": "0b8b78f9d08dc338a146eb4cd4bcbed8dd36a783" }, "nvim-treesitter-context": { "branch": "master", "commit": "0f3332788e0bd37716fbd25f39120dcfd557c90f" }, "nvim-web-devicons": { "branch": "master", "commit": "3722e3d1fb5fe1896a104eb489e8f8651260b520" }, "plenary.nvim": { "branch": "master", "commit": "ec289423a1693aeae6cd0d503bac2856af74edaa" }, diff --git a/nvim/lua/config/lazy.lua b/nvim/lua/config/lazy.lua index 0b93d4e..89c356d 100644 --- a/nvim/lua/config/lazy.lua +++ b/nvim/lua/config/lazy.lua @@ -29,7 +29,7 @@ require("lazy").setup({ }, -- Configure any other settings here. See the documentation for more details. -- colorscheme that will be used when installing plugins. - install = { colorscheme = { "habamax" } }, + install = { colorscheme = { "onedark" } }, -- automatically check for plugin updates checker = { enabled = false }, }) diff --git a/nvim/lua/config/options.lua b/nvim/lua/config/options.lua index 807f25c..36ec19f 100644 --- a/nvim/lua/config/options.lua +++ b/nvim/lua/config/options.lua @@ -4,6 +4,7 @@ vim.g.autoformat = false vim.opt.number = true vim.opt.relativenumber = true vim.opt.cursorline = true +vim.opt.termguicolors = true vim.opt.tabstop = 2 vim.opt.shiftwidth = 2 @@ -20,7 +21,8 @@ vim.opt.undofile = true vim.o.termguicolors = false vim.opt.guicursor = "n-v-c:block,i:block,r:block" -vim.opt.fillchars = { eob = " " } + +--vim.opt.fillchars = { eob = " " } vim.cmd([[ autocmd FileType python,haskell,c,cpp setlocal tabstop=4 shiftwidth=4 softtabstop=4 diff --git a/nvim/lua/plugins/bufferline.lua b/nvim/lua/plugins/bufferline.lua new file mode 100644 index 0000000..307cc1b --- /dev/null +++ b/nvim/lua/plugins/bufferline.lua @@ -0,0 +1,10 @@ +return { + { + "akinsho/bufferline.nvim", + version = "*", + dependencies = "nvim-tree/nvim-web-devicons", + config = function() + require("bufferline").setup{} + end + } +} diff --git a/nvim/lua/plugins/colorscheme.lua b/nvim/lua/plugins/colorscheme.lua index 6a74597..f434453 100644 --- a/nvim/lua/plugins/colorscheme.lua +++ b/nvim/lua/plugins/colorscheme.lua @@ -23,6 +23,11 @@ return { hi TelescopeSelection guibg=Gray guifg=Green gui=bold ctermbg=Black ctermfg=Green cterm=bold hi TelescopePreviewMatch ctermbg=Yellow ctermfg=Black guibg=Yellow guifg=Black + + hi TreesitterContext guibg=NONE ctermbg=NONE + + hi LazyProp guibg=NONE ctermbg=NONE + hi IblScope guibg=NONE guifg=Yellow ctermbg=NONE ctermfg=Yellow ]]) vim.api.nvim_create_autocmd("TextYankPost", { diff --git a/nvim/lua/plugins/indent-blankline.lua b/nvim/lua/plugins/indent-blankline.lua index 2af5796..599c900 100644 --- a/nvim/lua/plugins/indent-blankline.lua +++ b/nvim/lua/plugins/indent-blankline.lua @@ -1,5 +1,16 @@ return { { "lukas-reineke/indent-blankline.nvim", + config = function() + require("ibl").setup({ + --indent = { char = "│" }, + --indent = { char = "⎸" }, + indent = { char = "┆" }, + scope = { + show_start = false, + show_end = false + }, + }) + end, } } diff --git a/nvim/lua/plugins/lsp.lua b/nvim/lua/plugins/lsp.lua index ad5d79e..c16d08c 100644 --- a/nvim/lua/plugins/lsp.lua +++ b/nvim/lua/plugins/lsp.lua @@ -27,7 +27,6 @@ return { }, auto_install = true, sync_install = true, - ignore_install = {}, } end }, @@ -49,15 +48,14 @@ return { zindex = 20, -- The Z-index of the context window on_attach = nil, -- (fun(buf: integer): boolean) rurn false to disable attaching }) - vim.cmd([[ - hi TreesitterContext guibg=NONE ctermbg=NONE - ]]) end, }, { "neovim/nvim-lspconfig", config = function() + local lsp = require('lspconfig') + lsp.lua_ls.setup{} require("which-key").add({ { "cl", ":LspInfo", desc = "LSP Info" }, }) @@ -66,7 +64,16 @@ return { { "williamboman/mason.nvim", + config = function() + require("mason").setup{} + end + }, + + { "williamboman/mason-lspconfig.nvim", + config = function() + require("mason-lspconfig").setup{} + end }, { diff --git a/nvim/lua/plugins/neotree.lua b/nvim/lua/plugins/neotree.lua index d6e32ef..a0671bc 100644 --- a/nvim/lua/plugins/neotree.lua +++ b/nvim/lua/plugins/neotree.lua @@ -16,9 +16,35 @@ return { -- hijack_netrw_behavior = "disabled", --}, }) + + local function toggle_neotree() + local api = vim.api + local win = api.nvim_get_current_win() + local bufs = api.nvim_list_bufs() + + for _, buf in ipairs(bufs) do + local name = api.nvim_buf_get_name(buf) + if name:match("neo%-tree filesystem") then + api.nvim_command(":Neotree close") + return + end + end + + api.nvim_command(":Neotree") + end + require("which-key").add({ - { "e", ":Neotree", desc = "Neotree" } + { "e", toggle_neotree, desc = "File Explorer" } }) + + vim.fn.sign_define("DiagnosticSignError", + {text = " ", texthl = "DiagnosticSignError"}) + vim.fn.sign_define("DiagnosticSignWarn", + {text = " ", texthl = "DiagnosticSignWarn"}) + vim.fn.sign_define("DiagnosticSignInfo", + {text = " ", texthl = "DiagnosticSignInfo"}) + vim.fn.sign_define("DiagnosticSignHint", + {text = "󰌵", texthl = "DiagnosticSignHint"}) end, }, } diff --git a/nvim/lua/plugins/telescope.lua b/nvim/lua/plugins/telescope.lua index 2c150af..e84cc63 100644 --- a/nvim/lua/plugins/telescope.lua +++ b/nvim/lua/plugins/telescope.lua @@ -21,7 +21,6 @@ return { }, config = function() -- Custom Telescope command to grep from Git root - vim.api.nvim_set_keymap('n', 'lg', "lua require('telescope.builtin').live_grep({ cwd = git_root() })", { noremap = true, silent = true }) require("which-key").add({ { "/", function() require('telescope.builtin').live_grep({ cwd = git_root() }) @@ -38,7 +37,7 @@ return { { "gi", ":Telescope lsp_implementations", desc = "Go to Implementations" }, { "gt", ":Telescope lsp_type_definitions", desc = "Go to Type Definition" }, { "cv", ":Telescope treesitter", desc = "List function names & variables" }, - { "ca", ":Telescope diagnostics", desc = "Code diagnostics" }, + { "cd", ":Telescope diagnostics", desc = "Code diagnostics" }, -- Git { "Gt", ":Telescope git_branches", desc = "Git Branches" },