improve lazy-loading significantly and remove unused plugins
This commit is contained in:
+7
-2
@@ -16,6 +16,8 @@ return {
|
||||
{ -- Codeium
|
||||
import = 'lazyvim.plugins.extras.ai.codeium',
|
||||
cond = require('data.cond').codeium,
|
||||
event = 'VeryLazy',
|
||||
lazy = true,
|
||||
opts = function()
|
||||
require('codeium.virtual_text').set_statusbar_refresh(function()
|
||||
require('lualine').refresh()
|
||||
@@ -26,6 +28,9 @@ return {
|
||||
import = 'lazyvim.plugins.extras.ai.copilot',
|
||||
cond = require('data.cond').copilot,
|
||||
},
|
||||
{ -- Copilot
|
||||
import = 'lazyvim.plugins.extras.ai.copilot-chat',
|
||||
},
|
||||
{ -- Tabnine
|
||||
import = 'lazyvim.plugins.extras.ai.tabnine',
|
||||
cond = require('data.cond').tabnine,
|
||||
@@ -54,8 +59,7 @@ return {
|
||||
{ -- Avante
|
||||
'yetone/avante.nvim',
|
||||
cond = require('data.cond').avante,
|
||||
event = 'VeryLazy',
|
||||
lazy = false,
|
||||
lazy = true,
|
||||
opts = require('data.types').avante,
|
||||
build = 'make',
|
||||
dependencies = require('data.deps').avante,
|
||||
@@ -65,5 +69,6 @@ return {
|
||||
require('data.func').add_keymap(item)
|
||||
end
|
||||
end,
|
||||
cmd = 'Avante',
|
||||
},
|
||||
}
|
||||
|
||||
+7
-41
@@ -5,7 +5,6 @@
|
||||
-- ╰─────────────────────────────────────────────────────────╯
|
||||
|
||||
return {
|
||||
-- { import = "lazyvim.plugins.extras.coding.blink" },
|
||||
{ -- Mason-lspconfig
|
||||
'williamboman/mason-lspconfig.nvim',
|
||||
opts = require('data.types').mason_lsp_config.opts,
|
||||
@@ -16,6 +15,12 @@ return {
|
||||
{ -- nvim-treesitter
|
||||
'nvim-treesitter/nvim-treesitter',
|
||||
opts = require('data.types').treesitter.opts,
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
cond = function()
|
||||
-- Only load for editable buffers
|
||||
return vim.bo.buftype == '' and not vim.bo.readonly
|
||||
end,
|
||||
},
|
||||
{ -- nvim-lspconfig
|
||||
'neovim/nvim-lspconfig',
|
||||
@@ -93,7 +98,7 @@ return {
|
||||
},
|
||||
{
|
||||
'oskarrrrrrr/symbols.nvim',
|
||||
cmd = { 'Symbols', 'SymbolsToggle', 'SymbolsOpen', 'SymbolsClose' },
|
||||
cmd = require('data.cmd').symbols,
|
||||
config = function()
|
||||
local r = require('symbols.recipes')
|
||||
require('symbols').setup(r.DefaultFilters, r.AsciiSymbols, {
|
||||
@@ -119,43 +124,4 @@ return {
|
||||
lazy = false,
|
||||
priority = 1000,
|
||||
},
|
||||
{
|
||||
'philosofonusus/ecolog.nvim',
|
||||
dependencies = {
|
||||
'hrsh7th/nvim-cmp', -- Optional, for autocompletion support
|
||||
},
|
||||
-- Optionally reccommend adding keybinds (I use them personally)
|
||||
keys = function()
|
||||
if pcall(require, 'which-key') then
|
||||
require('which-key').add({ lhs = '<leader>qe', group = 'Ecolog' })
|
||||
return {
|
||||
{ '<leader>qeg', '<cmd>EcologGoto<cr>', desc = 'Go to env file' },
|
||||
{ '<leader>qes', '<cmd>EcologSelect<cr>', desc = 'Switch env file' },
|
||||
{
|
||||
'<leader>qep',
|
||||
'<cmd>EcologPeek<cr>',
|
||||
desc = 'Ecolog peek variable',
|
||||
},
|
||||
}
|
||||
end
|
||||
end,
|
||||
lazy = false,
|
||||
opts = {
|
||||
-- Enables shelter mode for sensitive values
|
||||
shelter = {
|
||||
configuration = {
|
||||
partial_mode = false, -- Disables partial mode see shelter configuration below
|
||||
mask_char = '*', -- Character used for masking
|
||||
},
|
||||
modules = {
|
||||
cmp = true, -- Mask values in completion
|
||||
peek = false, -- Mask values in peek view
|
||||
files = false, -- Mask values in files
|
||||
telescope = false, -- Mask values in telescope
|
||||
},
|
||||
},
|
||||
path = vim.fn.getcwd(), -- Path to search for .env files
|
||||
preferred_environment = 'development', -- Optional: prioritize specific env files
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
+14
-25
@@ -55,6 +55,8 @@ return {
|
||||
},
|
||||
{ -- Trouble
|
||||
'folke/trouble.nvim',
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
cmd = require('data.cmd').trouble,
|
||||
opts = require('data.types').trouble.opts,
|
||||
},
|
||||
@@ -66,16 +68,21 @@ return {
|
||||
{ -- NeoTree
|
||||
'nvim-neo-tree/neo-tree.nvim',
|
||||
opts = require('data.types').neotree.opts,
|
||||
cond = require('data.cond').neotree,
|
||||
},
|
||||
{ -- Arrow
|
||||
'otavioschwanck/arrow.nvim',
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
opts = require('data.types').arrow,
|
||||
},
|
||||
{ -- indent-blankline
|
||||
'lukas-reineke/indent-blankline.nvim',
|
||||
main = 'ibl',
|
||||
lazy = true,
|
||||
},
|
||||
-- { -- indent-blankline
|
||||
-- 'lukas-reineke/indent-blankline.nvim',
|
||||
-- main = 'ibl',
|
||||
-- lazy = true,
|
||||
-- event = 'LazyFile',
|
||||
-- cond = require('data.cond').lualine,
|
||||
-- },
|
||||
---@module "neominimap.config.meta"
|
||||
{ -- NeoMiniMap
|
||||
'Isrothy/neominimap.nvim',
|
||||
@@ -100,15 +107,10 @@ return {
|
||||
opts = {},
|
||||
keys = require('data.keys').precog,
|
||||
},
|
||||
{ -- Zen Mode
|
||||
'folke/zen-mode.nvim',
|
||||
lazy = true,
|
||||
opts = require('data.types').zen,
|
||||
keys = require('data.keys').zen,
|
||||
},
|
||||
{ -- Smart Scrolloff
|
||||
'tonymajestro/smart-scrolloff.nvim',
|
||||
event = 'VeryLazy',
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
cond = require('data.func').check_global_var('smart_scrolloff', true, true),
|
||||
opts = require('data.types').smartscrolloff,
|
||||
},
|
||||
@@ -164,10 +166,6 @@ return {
|
||||
'tamton-aquib/duck.nvim',
|
||||
config = require('data.types').duck,
|
||||
},
|
||||
{ -- Twilight
|
||||
'folke/twilight.nvim',
|
||||
opts = require('data.types').twilight,
|
||||
},
|
||||
{ -- Smear Cursor
|
||||
'sphamba/smear-cursor.nvim',
|
||||
event = 'VeryLazy',
|
||||
@@ -187,15 +185,6 @@ return {
|
||||
},
|
||||
},
|
||||
},
|
||||
{ -- Neoscroll
|
||||
'karb94/neoscroll.nvim',
|
||||
event = 'VeryLazy',
|
||||
enabled = function() -- Allow kitty and neovide to use native features
|
||||
return not require('data.func').is_neovide()
|
||||
and not require('data.func').is_kitty()
|
||||
end,
|
||||
opts = {},
|
||||
},
|
||||
{ -- Unimpaired
|
||||
'tpope/vim-unimpaired',
|
||||
config = true,
|
||||
|
||||
+4
-2
@@ -40,7 +40,8 @@ return {
|
||||
},
|
||||
{ -- Git Blame
|
||||
'f-person/git-blame.nvim',
|
||||
event = 'VeryLazy',
|
||||
event = 'LazyFile',
|
||||
cond = require('data.cond').lualine,
|
||||
opts = require('data.types').gitblame.opts,
|
||||
},
|
||||
{ -- Git Graph
|
||||
@@ -50,7 +51,8 @@ return {
|
||||
},
|
||||
{ -- Diffview
|
||||
'sindrets/diffview.nvim',
|
||||
lazy = false,
|
||||
lazy = true,
|
||||
cmd = require('data.cmd').diffview,
|
||||
opts = {},
|
||||
},
|
||||
{ -- Neogit
|
||||
|
||||
@@ -72,7 +72,7 @@ return {
|
||||
},
|
||||
{ -- Markdown Preview
|
||||
'iamcco/markdown-preview.nvim',
|
||||
cmd = { 'MarkdownPreviewToggle', 'MarkdownPreview', 'MarkdownPreviewStop' },
|
||||
cmd = require('data.cmd').markdown_preview,
|
||||
ft = { 'markdown' },
|
||||
build = function()
|
||||
vim.fn['mkdp#util#install']()
|
||||
|
||||
@@ -10,9 +10,9 @@ return {
|
||||
event = 'VeryLazy',
|
||||
opts = {},
|
||||
},
|
||||
{ -- Mini.Indentscope
|
||||
import = 'lazyvim.plugins.extras.ui.mini-indentscope',
|
||||
},
|
||||
-- { -- Mini.Indentscope
|
||||
-- import = 'lazyvim.plugins.extras.ui.mini-indentscope',
|
||||
-- },
|
||||
{ -- Mini Indentscope
|
||||
'echasnovski/mini.indentscope',
|
||||
opts = require('data.types').miniindentscope.opts,
|
||||
@@ -36,6 +36,9 @@ return {
|
||||
'echasnovski/mini.surround',
|
||||
opts = {},
|
||||
},
|
||||
{ -- mini.files
|
||||
import = 'lazyvim.plugins.extras.editor.mini-files',
|
||||
},
|
||||
{ -- mini.files
|
||||
'echasnovski/mini.files',
|
||||
opts = require('data.types').minifiles.opts,
|
||||
|
||||
@@ -74,7 +74,7 @@ return {
|
||||
},
|
||||
{ -- ToggleTerm
|
||||
'akinsho/toggleterm.nvim',
|
||||
event = 'VeryLazy',
|
||||
event = 'TermOpen',
|
||||
keys = require('data.keys').toggleterm,
|
||||
config = function()
|
||||
require('toggleterm').setup(require('data.types').toggleterm)
|
||||
@@ -120,4 +120,10 @@ return {
|
||||
end,
|
||||
cond = require('data.func').is_tmux(),
|
||||
},
|
||||
{ -- Ghostyy
|
||||
'isak102/ghostty.nvim',
|
||||
config = function()
|
||||
require('ghostty').setup()
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
+27
-29
@@ -13,6 +13,12 @@ return {
|
||||
},
|
||||
{ -- Env file no diagnostics
|
||||
'nvim-treesitter/nvim-treesitter',
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
cond = function()
|
||||
-- Only load for editable buffers
|
||||
return vim.bo.buftype == '' and not vim.bo.readonly
|
||||
end,
|
||||
opts = function(_)
|
||||
vim.api.nvim_create_augroup('EnvFileDiagnostics', { clear = true })
|
||||
|
||||
@@ -62,7 +68,10 @@ return {
|
||||
},
|
||||
{ -- Hardtime
|
||||
'm4xshen/hardtime.nvim',
|
||||
lazy = false,
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
cond = require('data.func').check_global_var('usehardtime', true, true),
|
||||
build = 'make',
|
||||
dependencies = require('data.deps').hardtime,
|
||||
opts = function()
|
||||
return { enabled = vim.g.usehardtime }
|
||||
@@ -84,6 +93,7 @@ return {
|
||||
},
|
||||
{ -- Qalc
|
||||
'Apeiros-46B/qalc.nvim',
|
||||
lazy = true,
|
||||
cmd = require('data.cmd').qalc,
|
||||
keys = require('data.keys').qalc,
|
||||
opts = {
|
||||
@@ -121,13 +131,10 @@ return {
|
||||
cmd = require('data.cmd').suda,
|
||||
config = require('data.types').suda,
|
||||
},
|
||||
-- { -- Pigeon
|
||||
-- "Pheon-Dev/pigeon",
|
||||
-- config = require('data.types').pigeon,
|
||||
-- },
|
||||
{ -- Discord Presence
|
||||
'IogaMaster/neocord',
|
||||
event = 'VeryLazy',
|
||||
lazy = true,
|
||||
cond = require('data.func').check_global_var('usediscord', true, true),
|
||||
opts = {
|
||||
logo = 'https://raw.githubusercontent.com/rootiest/rootiest-nvim/b949af32e72db9fc35c18e14e2088710dc36dd15/logo/icon.png',
|
||||
@@ -138,17 +145,14 @@ return {
|
||||
},
|
||||
{ -- Floating Help
|
||||
'Tyler-Barham/floating-help.nvim',
|
||||
lazy = true,
|
||||
opts = {
|
||||
width = 0.8, -- Whole numbers are columns/rows
|
||||
height = 0.9, -- Decimals are a percentage of the editor
|
||||
position = 'C', -- NW,N,NW,W,C,E,SW,S,SE (C==center)
|
||||
border = 'rounded', -- rounded,double,single
|
||||
},
|
||||
cmd = {
|
||||
'FloatingHelp',
|
||||
'FloatingHelpClose',
|
||||
'FloatingHelpToggle',
|
||||
},
|
||||
cmd = require('data.cmd').floating_help,
|
||||
init = function()
|
||||
vim.g.floating_help = true
|
||||
-- Only replace cmds, not search; only replace the first instance
|
||||
@@ -174,10 +178,12 @@ return {
|
||||
},
|
||||
{ -- Timer
|
||||
'alex-popov-tech/timer.nvim',
|
||||
lazy = true,
|
||||
},
|
||||
{ -- Image-Clip
|
||||
'HakonHarnes/img-clip.nvim',
|
||||
event = 'VeryLazy',
|
||||
lazy = true,
|
||||
cmd = require('data.cmd').imgclip,
|
||||
opts = {
|
||||
default = {
|
||||
embed_image_as_base64 = false,
|
||||
@@ -193,6 +199,8 @@ return {
|
||||
{ -- Multicursor
|
||||
'jake-stewart/multicursor.nvim',
|
||||
branch = '1.0',
|
||||
lazy = true,
|
||||
event = 'LazyFile',
|
||||
config = function()
|
||||
local mc = require('multicursor-nvim')
|
||||
|
||||
@@ -206,23 +214,10 @@ return {
|
||||
})
|
||||
end,
|
||||
},
|
||||
{
|
||||
'itsvinayak/nvim-notes.nvim',
|
||||
dependencies = {
|
||||
'nvim-telescope/telescope.nvim', -- Add Telescope as a dependency
|
||||
'folke/which-key.nvim', -- Add WhichKey as a dependency
|
||||
},
|
||||
config = function()
|
||||
require('notes').setup({
|
||||
-- Optional configurations
|
||||
path = '~/.my_notes', -- Custom path for notes
|
||||
log_enabled = true, -- Enable logging
|
||||
log_level = 'INFO', -- Set log level to INFO
|
||||
})
|
||||
end,
|
||||
},
|
||||
{ -- FloatTerm
|
||||
'voldikss/vim-floaterm',
|
||||
lazy = true,
|
||||
event = 'TermOpen',
|
||||
},
|
||||
{ -- bufferlist
|
||||
'EL-MASTOR/bufferlist.nvim',
|
||||
@@ -232,6 +227,7 @@ return {
|
||||
},
|
||||
{ -- showkeys
|
||||
'nvchad/showkeys',
|
||||
lazy = true,
|
||||
cmd = 'ShowkeysToggle',
|
||||
opts = {
|
||||
timeout = 1,
|
||||
@@ -241,9 +237,9 @@ return {
|
||||
},
|
||||
{
|
||||
'stevearc/oil.nvim',
|
||||
---@module 'oil'
|
||||
---@type oil.SetupOpts
|
||||
opts = {},
|
||||
lazy = true,
|
||||
cond = require('data.func').check_global_var('useoil', true, true),
|
||||
-- Optional dependencies
|
||||
dependencies = { { 'echasnovski/mini.icons', opts = {} } },
|
||||
-- dependencies = { "nvim-tree/nvim-web-devicons" }, -- use if prefer nvim-web-devicons
|
||||
@@ -278,18 +274,20 @@ return {
|
||||
-- when the profiler is running
|
||||
{
|
||||
'nvim-lualine/lualine.nvim',
|
||||
cond = require('data.cond').lualine,
|
||||
opts = function(_, opts)
|
||||
table.insert(opts.sections.lualine_x, Snacks.profiler.status())
|
||||
end,
|
||||
},
|
||||
{
|
||||
'marcussimonsen/let-it-snow.nvim',
|
||||
lazy = true,
|
||||
cmd = 'LetItSnow', -- Wait with loading until command is run
|
||||
opts = {},
|
||||
},
|
||||
{ -- yazi
|
||||
'mikavilpas/yazi.nvim',
|
||||
lazy = true,
|
||||
cmd = 'Yazi',
|
||||
event = 'VeryLazy',
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user