added custom config

This commit is contained in:
Subhadip Ghosh 2024-09-13 13:00:08 +05:30
parent a22976111e
commit 0c0583579c
1 changed files with 247 additions and 110 deletions

357
init.lua
View File

@ -90,8 +90,8 @@ P.S. You can delete this when you're done too. It's your config now! :)
vim.g.mapleader = ' ' vim.g.mapleader = ' '
vim.g.maplocalleader = ' ' vim.g.maplocalleader = ' '
-- Set to true if you have a Nerd Font installed and selected in the terminal -- Set to true if you have a Nerd Font installed
vim.g.have_nerd_font = false vim.g.have_nerd_font = true
-- [[ Setting options ]] -- [[ Setting options ]]
-- See `:help vim.opt` -- See `:help vim.opt`
@ -102,7 +102,7 @@ vim.g.have_nerd_font = false
vim.opt.number = true vim.opt.number = true
-- You can also add relative line numbers, to help with jumping. -- You can also add relative line numbers, to help with jumping.
-- Experiment for yourself to see if you like it! -- Experiment for yourself to see if you like it!
-- vim.opt.relativenumber = true vim.opt.relativenumber = true
-- Enable mouse mode, can be useful for resizing splits for example! -- Enable mouse mode, can be useful for resizing splits for example!
vim.opt.mouse = 'a' vim.opt.mouse = 'a'
@ -111,12 +111,9 @@ vim.opt.mouse = 'a'
vim.opt.showmode = false vim.opt.showmode = false
-- Sync clipboard between OS and Neovim. -- Sync clipboard between OS and Neovim.
-- Schedule the setting after `UiEnter` because it can increase startup-time.
-- Remove this option if you want your OS clipboard to remain independent. -- Remove this option if you want your OS clipboard to remain independent.
-- See `:help 'clipboard'` -- See `:help 'clipboard'`
vim.schedule(function() vim.opt.clipboard = 'unnamedplus'
vim.opt.clipboard = 'unnamedplus'
end)
-- Enable break indent -- Enable break indent
vim.opt.breakindent = true vim.opt.breakindent = true
@ -145,7 +142,7 @@ vim.opt.splitbelow = true
-- Sets how neovim will display certain whitespace characters in the editor. -- Sets how neovim will display certain whitespace characters in the editor.
-- See `:help 'list'` -- See `:help 'list'`
-- and `:help 'listchars'` -- and `:help 'listchars'`
vim.opt.list = true vim.opt.list = false
vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '' } vim.opt.listchars = { tab = '» ', trail = '·', nbsp = '' }
-- Preview substitutions live, as you type! -- Preview substitutions live, as you type!
@ -157,16 +154,27 @@ vim.opt.cursorline = true
-- Minimal number of screen lines to keep above and below the cursor. -- Minimal number of screen lines to keep above and below the cursor.
vim.opt.scrolloff = 10 vim.opt.scrolloff = 10
vim.opt.tabstop = 4
vim.opt.shiftwidth = 4
-- vim.opt.background = 'light'
-- [[ Basic Keymaps ]] -- [[ Basic Keymaps ]]
-- See `:help vim.keymap.set()` -- See `:help vim.keymap.set()`
-- Clear highlights on search when pressing <Esc> in normal mode -- Set highlight on search, but clear on pressing <Esc> in normal mode
-- See `:help hlsearch` vim.opt.hlsearch = true
vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>') vim.keymap.set('n', '<Esc>', '<cmd>nohlsearch<CR>')
-- Diagnostic keymaps -- Diagnostic keymaps
vim.keymap.set('n', '[d', vim.diagnostic.goto_prev, { desc = 'Go to previous [D]iagnostic message' })
vim.keymap.set('n', ']d', vim.diagnostic.goto_next, { desc = 'Go to next [D]iagnostic message' })
vim.keymap.set('n', '<leader>e', vim.diagnostic.open_float, { desc = 'Show diagnostic [E]rror messages' })
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' }) vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })
vim.keymap.set('n', '<leader>th', ':Telescope colorscheme<CR>', { desc = 'Colorschemes ' })
vim.keymap.set('n', '<leader>tb', ':Telescope buffers<CR>', { desc = 'Open Buffers ' })
-- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier -- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier
-- for people to discover. Otherwise, you normally need to press <C-\><C-n>, which -- for people to discover. Otherwise, you normally need to press <C-\><C-n>, which
-- is not what someone will guess without a bit more experience. -- is not what someone will guess without a bit more experience.
@ -190,6 +198,35 @@ vim.keymap.set('n', '<C-l>', '<C-w><C-l>', { desc = 'Move focus to the right win
vim.keymap.set('n', '<C-j>', '<C-w><C-j>', { desc = 'Move focus to the lower window' }) vim.keymap.set('n', '<C-j>', '<C-w><C-j>', { desc = 'Move focus to the lower window' })
vim.keymap.set('n', '<C-k>', '<C-w><C-k>', { desc = 'Move focus to the upper window' }) vim.keymap.set('n', '<C-k>', '<C-w><C-k>', { desc = 'Move focus to the upper window' })
-- Keybindings to split windows
vim.keymap.set('n', '<leader>|', ':vsplit<CR>', { desc = 'split vertically' })
vim.keymap.set('n', '<leader>-', ':split<CR>', { desc = 'split horizontally' })
-- Misc keybindings
vim.keymap.set('n', '<leader>w', ':q<CR>', { desc = 'quit buffer' })
-- Height of window
vim.keymap.set('n', '<leader>h', ':vertical resize -10<CR>', { desc = 'vertically resize low' })
vim.keymap.set('n', '<leader>l', ':vertical resize +10<CR>', { desc = 'vertically resize high' })
vim.keymap.set('n', '<leader>j', ':resize +10<CR>', { desc = 'resize more' })
vim.keymap.set('n', '<leader>k', ':resize +10<CR>', { desc = 'resize less' })
-- Nvimtree
vim.keymap.set('n', '<leader>n', ':NvimTreeFindFileToggle<CR>', { desc = 'nvim tree' })
-- Git Diff View
vim.keymap.set('n', '<leader>gd', ':DiffviewOpen<CR>', { desc = 'diff view open' })
vim.keymap.set('n', '<leader>gcd', ':DiffviewClose<CR>', { desc = 'diff view close' })
vim.keymap.set('n', '<leader>rh', ':Gitsigns reset_hunk<CR>', { desc = 'Reset Hunk' })
-- Tab nav
vim.keymap.set('n', '<Tab>', ':bNext<CR>', { desc = 'next buffer' })
vim.keymap.set('n', '<S-Tab>', ':bprevious<CR>', { desc = 'previous buffer' })
-- colorscheme
-- vim.cmd.colorscheme = 'flow'
-- [[ Basic Autocommands ]] -- [[ Basic Autocommands ]]
-- See `:help lua-guide-autocommands` -- See `:help lua-guide-autocommands`
@ -209,10 +246,7 @@ vim.api.nvim_create_autocmd('TextYankPost', {
local lazypath = vim.fn.stdpath 'data' .. '/lazy/lazy.nvim' local lazypath = vim.fn.stdpath 'data' .. '/lazy/lazy.nvim'
if not (vim.uv or vim.loop).fs_stat(lazypath) then if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = 'https://github.com/folke/lazy.nvim.git' local lazyrepo = 'https://github.com/folke/lazy.nvim.git'
local out = vim.fn.system { 'git', 'clone', '--filter=blob:none', '--branch=stable', lazyrepo, lazypath } vim.fn.system { 'git', 'clone', '--filter=blob:none', '--branch=stable', lazyrepo, lazypath }
if vim.v.shell_error ~= 0 then
error('Error cloning lazy.nvim:\n' .. out)
end
end ---@diagnostic disable-next-line: undefined-field end ---@diagnostic disable-next-line: undefined-field
vim.opt.rtp:prepend(lazypath) vim.opt.rtp:prepend(lazypath)
@ -237,6 +271,11 @@ require('lazy').setup({
-- --
-- Use `opts = {}` to force a plugin to be loaded. -- Use `opts = {}` to force a plugin to be loaded.
-- --
-- This is equivalent to:
-- require('Comment').setup({})
-- "gc" to comment visual regions/lines
{ 'numToStr/Comment.nvim', opts = {} },
-- Here is a more advanced example where we pass configuration -- Here is a more advanced example where we pass configuration
-- options to `gitsigns.nvim`. This is equivalent to the following Lua: -- options to `gitsigns.nvim`. This is equivalent to the following Lua:
@ -253,6 +292,7 @@ require('lazy').setup({
topdelete = { text = '' }, topdelete = { text = '' },
changedelete = { text = '~' }, changedelete = { text = '~' },
}, },
current_line_blame = true, -- Toggle with `:Gitsigns toggle_current_line_blame`
}, },
}, },
@ -401,15 +441,15 @@ require('lazy').setup({
-- See `:help telescope.builtin` -- See `:help telescope.builtin`
local builtin = require 'telescope.builtin' local builtin = require 'telescope.builtin'
vim.keymap.set('n', '<leader>sh', builtin.help_tags, { desc = '[S]earch [H]elp' }) vim.keymap.set('n', '<leader>sh', builtin.help_tags, { desc = '[F]earch [H]elp' })
vim.keymap.set('n', '<leader>sk', builtin.keymaps, { desc = '[S]earch [K]eymaps' }) vim.keymap.set('n', '<leader>fk', builtin.keymaps, { desc = '[F]earch [K]eymaps' })
vim.keymap.set('n', '<leader>sf', builtin.find_files, { desc = '[S]earch [F]iles' }) vim.keymap.set('n', '<leader>ff', builtin.find_files, { desc = '[F]earch [F]iles' })
vim.keymap.set('n', '<leader>ss', builtin.builtin, { desc = '[S]earch [S]elect Telescope' }) vim.keymap.set('n', '<leader>fs', builtin.builtin, { desc = '[F]earch [S]elect Telescope' })
vim.keymap.set('n', '<leader>sw', builtin.grep_string, { desc = '[S]earch current [W]ord' }) vim.keymap.set('n', '<leader>fw', builtin.grep_string, { desc = '[F]earch current [W]ord' })
vim.keymap.set('n', '<leader>sg', builtin.live_grep, { desc = '[S]earch by [G]rep' }) vim.keymap.set('n', '<leader>fg', builtin.live_grep, { desc = '[F]earch by [G]rep' })
vim.keymap.set('n', '<leader>sd', builtin.diagnostics, { desc = '[S]earch [D]iagnostics' }) vim.keymap.set('n', '<leader>fd', builtin.diagnostics, { desc = '[F]earch [D]iagnostics' })
vim.keymap.set('n', '<leader>sr', builtin.resume, { desc = '[S]earch [R]esume' }) vim.keymap.set('n', '<leader>fr', builtin.resume, { desc = '[F]earch [R]esume' })
vim.keymap.set('n', '<leader>s.', builtin.oldfiles, { desc = '[S]earch Recent Files ("." for repeat)' }) vim.keymap.set('n', '<leader>s.', builtin.oldfiles, { desc = '[F]earch Recent Files ("." for repeat)' })
vim.keymap.set('n', '<leader><leader>', builtin.buffers, { desc = '[ ] Find existing buffers' }) vim.keymap.set('n', '<leader><leader>', builtin.buffers, { desc = '[ ] Find existing buffers' })
-- Slightly advanced example of overriding default behavior and theme -- Slightly advanced example of overriding default behavior and theme
@ -437,26 +477,11 @@ require('lazy').setup({
end, end,
}, },
-- LSP Plugins { -- LSP Configuration & Plugins
{
-- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
-- used for completion, annotations and signatures of Neovim apis
'folke/lazydev.nvim',
ft = 'lua',
opts = {
library = {
-- Load luvit types when the `vim.uv` word is found
{ path = 'luvit-meta/library', words = { 'vim%.uv' } },
},
},
},
{ 'Bilal2453/luvit-meta', lazy = true },
{
-- Main LSP Configuration
'neovim/nvim-lspconfig', 'neovim/nvim-lspconfig',
dependencies = { dependencies = {
-- Automatically install LSPs and related tools to stdpath for Neovim -- Automatically install LSPs and related tools to stdpath for Neovim
{ 'williamboman/mason.nvim', config = true }, -- NOTE: Must be loaded before dependants 'williamboman/mason.nvim',
'williamboman/mason-lspconfig.nvim', 'williamboman/mason-lspconfig.nvim',
'WhoIsSethDaniel/mason-tool-installer.nvim', 'WhoIsSethDaniel/mason-tool-installer.nvim',
@ -464,8 +489,9 @@ require('lazy').setup({
-- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})` -- NOTE: `opts = {}` is the same as calling `require('fidget').setup({})`
{ 'j-hui/fidget.nvim', opts = {} }, { 'j-hui/fidget.nvim', opts = {} },
-- Allows extra capabilities provided by nvim-cmp -- `neodev` configures Lua LSP for your Neovim config, runtime and plugins
'hrsh7th/cmp-nvim-lsp', -- used for completion, annotations and signatures of Neovim apis
{ 'folke/neodev.nvim', opts = {} },
}, },
config = function() config = function()
-- Brief aside: **What is LSP?** -- Brief aside: **What is LSP?**
@ -541,7 +567,11 @@ require('lazy').setup({
-- Execute a code action, usually your cursor needs to be on top of an error -- Execute a code action, usually your cursor needs to be on top of an error
-- or a suggestion from your LSP for this to activate. -- or a suggestion from your LSP for this to activate.
map('<leader>ca', vim.lsp.buf.code_action, '[C]ode [A]ction', { 'n', 'x' }) map('<leader>cs', vim.lsp.buf.code_action, '[C]ode [A]ction', { 'n', 'x' })
-- Opens a popup that displays documentation about the word under your cursor
-- See `:help K` for why this keymap.
map('K', vim.lsp.buf.hover, 'Hover Documentation')
-- WARN: This is not Goto Definition, this is Goto Declaration. -- WARN: This is not Goto Definition, this is Goto Declaration.
-- For example, in C this would take you to the header. -- For example, in C this would take you to the header.
@ -553,37 +583,16 @@ require('lazy').setup({
-- --
-- When you move your cursor, the highlights will be cleared (the second autocommand). -- When you move your cursor, the highlights will be cleared (the second autocommand).
local client = vim.lsp.get_client_by_id(event.data.client_id) local client = vim.lsp.get_client_by_id(event.data.client_id)
if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_documentHighlight) then if client and client.server_capabilities.documentHighlightProvider then
local highlight_augroup = vim.api.nvim_create_augroup('kickstart-lsp-highlight', { clear = false })
vim.api.nvim_create_autocmd({ 'CursorHold', 'CursorHoldI' }, { vim.api.nvim_create_autocmd({ 'CursorHold', 'CursorHoldI' }, {
buffer = event.buf, buffer = event.buf,
group = highlight_augroup,
callback = vim.lsp.buf.document_highlight, callback = vim.lsp.buf.document_highlight,
}) })
vim.api.nvim_create_autocmd({ 'CursorMoved', 'CursorMovedI' }, { vim.api.nvim_create_autocmd({ 'CursorMoved', 'CursorMovedI' }, {
buffer = event.buf, buffer = event.buf,
group = highlight_augroup,
callback = vim.lsp.buf.clear_references, callback = vim.lsp.buf.clear_references,
}) })
vim.api.nvim_create_autocmd('LspDetach', {
group = vim.api.nvim_create_augroup('kickstart-lsp-detach', { clear = true }),
callback = function(event2)
vim.lsp.buf.clear_references()
vim.api.nvim_clear_autocmds { group = 'kickstart-lsp-highlight', buffer = event2.buf }
end,
})
end
-- The following code creates a keymap to toggle inlay hints in your
-- code, if the language server you are using supports them
--
-- This may be unwanted, since they displace some of your code
if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint) then
map('<leader>th', function()
vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled { bufnr = event.buf })
end, '[T]oggle Inlay [H]ints')
end end
end, end,
}) })
@ -615,7 +624,9 @@ require('lazy').setup({
-- https://github.com/pmizio/typescript-tools.nvim -- https://github.com/pmizio/typescript-tools.nvim
-- --
-- But for many setups, the LSP (`tsserver`) will work just fine -- But for many setups, the LSP (`tsserver`) will work just fine
-- tsserver = {}, tsserver = {
auto_format = false,
},
-- --
lua_ls = { lua_ls = {
@ -667,11 +678,10 @@ require('lazy').setup({
{ -- Autoformat { -- Autoformat
'stevearc/conform.nvim', 'stevearc/conform.nvim',
event = { 'BufWritePre' }, lazy = false,
cmd = { 'ConformInfo' },
keys = { keys = {
{ {
'<leader>f', '<leader>fm',
function() function()
require('conform').format { async = true, lsp_format = 'fallback' } require('conform').format { async = true, lsp_format = 'fallback' }
end, end,
@ -692,6 +702,10 @@ require('lazy').setup({
else else
lsp_format_opt = 'fallback' lsp_format_opt = 'fallback'
end end
local disable_global = { javascript = true, javascriptreact = true, typescript = true, typescriptreact = true }
if disable_global[vim.bo[bufnr].filetype] then
return
end
return { return {
timeout_ms = 500, timeout_ms = 500,
lsp_format = lsp_format_opt, lsp_format = lsp_format_opt,
@ -702,8 +716,12 @@ require('lazy').setup({
-- Conform can also run multiple formatters sequentially -- Conform can also run multiple formatters sequentially
-- python = { "isort", "black" }, -- python = { "isort", "black" },
-- --
-- You can use 'stop_after_first' to run the first available formatter from the list -- You can use a sub-list to tell conform to run *until* a formatter
-- javascript = { "prettierd", "prettier", stop_after_first = true }, -- is found.
javascript = { { 'prettier' } },
typescript = { { 'prettier' } },
javascriptreact = { { 'prettier' } },
typescriptreact = { { 'prettier' } },
}, },
}, },
}, },
@ -777,12 +795,6 @@ require('lazy').setup({
-- This will expand snippets if the LSP sent a snippet. -- This will expand snippets if the LSP sent a snippet.
['<C-y>'] = cmp.mapping.confirm { select = true }, ['<C-y>'] = cmp.mapping.confirm { select = true },
-- If you prefer more traditional completion keymaps,
-- you can uncomment the following lines
--['<CR>'] = cmp.mapping.confirm { select = true },
--['<Tab>'] = cmp.mapping.select_next_item(),
--['<S-Tab>'] = cmp.mapping.select_prev_item(),
-- Manually trigger a completion from nvim-cmp. -- Manually trigger a completion from nvim-cmp.
-- Generally you don't need this, because nvim-cmp will display -- Generally you don't need this, because nvim-cmp will display
-- completions whenever it has completion options available. -- completions whenever it has completion options available.
@ -806,16 +818,13 @@ require('lazy').setup({
luasnip.jump(-1) luasnip.jump(-1)
end end
end, { 'i', 's' }), end, { 'i', 's' }),
-- select on pressing enter
['<Return>'] = cmp.mapping.confirm { select = true },
-- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see: -- For more advanced Luasnip keymaps (e.g. selecting choice nodes, expansion) see:
-- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps -- https://github.com/L3MON4D3/LuaSnip?tab=readme-ov-file#keymaps
}, },
sources = { sources = {
{
name = 'lazydev',
-- set group index to 0 to skip loading LuaLS completions as lazydev recommends it
group_index = 0,
},
{ name = 'nvim_lsp' }, { name = 'nvim_lsp' },
{ name = 'luasnip' }, { name = 'luasnip' },
{ name = 'path' }, { name = 'path' },
@ -824,23 +833,23 @@ require('lazy').setup({
end, end,
}, },
{ -- You can easily change to a different colorscheme. -- { -- You can easily change to a different colorscheme.
-- Change the name of the colorscheme plugin below, and then -- -- Change the name of the colorscheme plugin below, and then
-- change the command in the config to whatever the name of that colorscheme is. -- -- change the command in the config to whatever the name of that colorscheme is.
-- -- --
-- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`. -- -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
'folke/tokyonight.nvim', -- 'folke/tokyonight.nvim',
priority = 1000, -- Make sure to load this before all the other start plugins. -- priority = 1000, -- Make sure to load this before all the other start plugins.
init = function() -- init = function()
-- Load the colorscheme here. -- -- Load the colorscheme here.
-- Like many other themes, this one has different styles, and you could load -- -- Like many other themes, this one has different styles, and you could load
-- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'. -- -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
vim.cmd.colorscheme 'tokyonight-night' -- vim.cmd.colorscheme 'tokyonight'
--
-- You can configure highlights by doing something like: -- -- You can configure highlights by doing something like:
vim.cmd.hi 'Comment gui=none' -- vim.cmd.hi 'Comment gui=none'
end, -- end,
}, -- },
-- Highlight todo, notes, etc in comments -- Highlight todo, notes, etc in comments
{ 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } }, { 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } },
@ -852,7 +861,7 @@ require('lazy').setup({
-- --
-- Examples: -- Examples:
-- - va) - [V]isually select [A]round [)]paren -- - va) - [V]isually select [A]round [)]paren
-- - yinq - [Y]ank [I]nside [N]ext [Q]uote -- - yinq - [Y]ank [I]nside [N]ext [']quote
-- - ci' - [C]hange [I]nside [']quote -- - ci' - [C]hange [I]nside [']quote
require('mini.ai').setup { n_lines = 500 } require('mini.ai').setup { n_lines = 500 }
@ -888,7 +897,7 @@ require('lazy').setup({
main = 'nvim-treesitter.configs', -- Sets main module to use for opts main = 'nvim-treesitter.configs', -- Sets main module to use for opts
-- [[ Configure Treesitter ]] See `:help nvim-treesitter` -- [[ Configure Treesitter ]] See `:help nvim-treesitter`
opts = { opts = {
ensure_installed = { 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'markdown_inline', 'query', 'vim', 'vimdoc' }, ensure_installed = { 'bash', 'c', 'html', 'lua', 'luadoc', 'markdown', 'vim', 'vimdoc' },
-- Autoinstall languages that are not installed -- Autoinstall languages that are not installed
auto_install = true, auto_install = true,
highlight = { highlight = {
@ -900,12 +909,143 @@ require('lazy').setup({
}, },
indent = { enable = true, disable = { 'ruby' } }, indent = { enable = true, disable = { 'ruby' } },
}, },
-- There are additional nvim-treesitter modules that you can use to interact config = function(_, opts)
-- with nvim-treesitter. You should go explore a few and see what interests you: -- [[ Configure Treesitter ]] See `:help nvim-treesitter`
--
-- - Incremental selection: Included, see `:help nvim-treesitter-incremental-selection-mod` ---@diagnostic disable-next-line: missing-fields
-- - Show your current context: https://github.com/nvim-treesitter/nvim-treesitter-context require('nvim-treesitter.configs').setup(opts)
-- - Treesitter + textobjects: https://github.com/nvim-treesitter/nvim-treesitter-textobjects
-- There are additional nvim-treesitter modules that you can use to interact
-- with nvim-treesitter. You should go explore a few and see what interests you:
--
-- - Incremental selection: Included, see `:help nvim-treesitter-incremental-selection-mod`
-- - Show your current context: https://github.com/nvim-treesitter/nvim-treesitter-context
-- - Treesitter + textobjects: https://github.com/nvim-treesitter/nvim-treesitter-textobjects
end,
},
{
'tjdevries/colorbuddy.vim',
},
{
'deparr/tairiki.nvim',
lazy = false,
-- priority = 1001,
-- init = function()
-- vim.cmd.colorscheme 'tairiki'
-- end,
},
{
'nvim-tree/nvim-tree.lua',
lazy = false,
dependencies = {
'kyazdani42/nvim-web-devicons',
},
config = function()
require('nvim-tree').setup {
sort = {
sorter = 'case_sensitive',
},
view = {
width = 30,
},
renderer = {
group_empty = true,
},
filters = {
dotfiles = true,
},
update_focused_file = {
enable = true,
},
}
end,
},
{
'tanvirtin/vgit.nvim',
dependencies = {
'nvim-lua/plenary.nvim',
},
},
{
'oxfist/night-owl.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.o.background = 'dark'
-- vim.cmd.colorscheme 'night-owl'
end,
},
{
'xiyaowong/transparent.nvim',
lazy = false,
config = function()
require('transparent').setup { -- Optional, you don't have to run setup.
groups = { -- table: default groups
'Normal',
'NormalNC',
'Comment',
'Constant',
'Special',
'Identifier',
'Statement',
'PreProc',
'Type',
'Underlined',
'Todo',
'String',
'Function',
'Conditional',
'Repeat',
'Operator',
'Structure',
'LineNr',
'NonText',
'SignColumn',
'CursorLine',
'CursorLineNr',
'StatusLine',
'StatusLineNC',
'EndOfBuffer',
},
extra_groups = {}, -- table: additional groups that should be cleared
exclude_groups = {}, -- table: groups you don't want to clear
}
end,
},
{
'windwp/nvim-autopairs',
event = 'InsertEnter',
config = true,
},
{
'sindrets/diffview.nvim',
config = true,
lazy = false,
opts = {
enhanced_diff_hl = false,
view = {
merge_tool = {
layout = 'diff3_mixed',
},
},
},
},
{
'Mofiqul/vscode.nvim',
lazy = false,
-- priority = 1001,
-- init = function()
-- vim.cmd.colorscheme 'vscode'
-- end,
},
{
'Yazeed1s/minimal.nvim',
lazy = false,
priority = 1001,
init = function()
vim.cmd.colorscheme 'minimal'
end,
}, },
-- The following two comments only work if you have downloaded the kickstart repo, not just copy pasted the -- The following two comments only work if you have downloaded the kickstart repo, not just copy pasted the
@ -920,9 +1060,6 @@ require('lazy').setup({
-- require 'kickstart.plugins.debug', -- require 'kickstart.plugins.debug',
-- require 'kickstart.plugins.indent_line', -- require 'kickstart.plugins.indent_line',
-- require 'kickstart.plugins.lint', -- require 'kickstart.plugins.lint',
-- require 'kickstart.plugins.autopairs',
-- require 'kickstart.plugins.neo-tree',
-- require 'kickstart.plugins.gitsigns', -- adds gitsigns recommend keymaps
-- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua` -- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua`
-- This is the easiest way to modularize your config. -- This is the easiest way to modularize your config.