Sitelet https://github.com/NormalNvim/NormalNvim/pull/477/files
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions lua/base/utils/lsp.lua
Original file line number Diff line number Diff line change
Expand Up @@ -153,10 +153,6 @@ function M.apply_user_lsp_settings(server_name)
local is_schemastore_loaded, schemastore = pcall(require, "schemastore")
if is_schemastore_loaded then opts.settings = { yaml = { schemas = schemastore.yaml.schemas() } } end
end
if server_name == "lua_ls" then -- Disable third party checking
pcall(require, "neodev")
opts.settings = { Lua = { workspace = { checkThirdParty = false } } }
end

-- Apply them
local old_on_attach = server.on_attach
Expand Down
5 changes: 3 additions & 2 deletions lua/lazy_snapshot.lua
Original file line number Diff line number Diff line change
@@ -1,26 +1,27 @@
return {
{ "AckslD/nvim-neoclip.lua", commit = "709c97fabec9da7d04f7d2f5e207423af8c02871" },
{ "AstroNvim/astrotheme", version = "^4" },
{ "Bilal2453/luvit-meta", commit = "ce76f6f6cdc9201523a5875a4471dcfe0186eb60" },
{ "Issafalcon/neotest-dotnet", commit = "caeb52b602fa8a5855c5839c338fb65b50a40ab3" },
{ "JavaHello/spring-boot.nvim", commit = "218c0c26c14d99feca778e4d13f5ec3e8b1b60f0" },
{ "L3MON4D3/LuaSnip", version = "^3" },
{ "MeanderingProgrammer/markdown.nvim", version = "^5" },
{ "MunifTanjim/nui.nvim", commit = "61574ce6e60c815b0a0c4b5655b8486ba58089a1" },
{ "NMAC427/guess-indent.nvim", commit = "6c75506e71836f34fe5c5efa322dfce3e0494e7b" },
{ "NvChad/nvim-colorizer.lua", commit = "08bd34bf0ed79723f62764c7f9ca70516d461d0d" },
{ "Shatur/neovim-session-manager", commit = "dd0f5ebb06431505a6de75fd1bc50cd62226adef" },
{ "akinsho/toggleterm.nvim", commit = "cd55bf6aab3f88c259fa29ea86bbdcb1a325687d" },
{ "andymass/vim-matchup", commit = "1535a769d5dca851fe7d41b0be95f7c7203a4bef" },
{ "b0o/SchemaStore.nvim", commit = "37274739232b6a888be7c6ca5f1a2d58510a9a84" },
{ "benfowler/telescope-luasnip.nvim", commit = "11668478677de360dea45cf2b090d34f21b8ae07" },
{ "brenoprata10/nvim-highlight-colors", commit = "a8f6952cb1ff7bde864a34c502f1a42c360a6662" },
{ "cappyzawa/trim.nvim", commit = "4fe47a46c02a58894ded8328ca81f6c214a892f5" },
{ "debugloop/telescope-undo.nvim", commit = "95b61c01ea3a4c9e8747731148e905bbcf0ccaee" },
{ "dense-analysis/neural", commit = "f53af0007124517a46b99a4d49b86087e426bfef" },
{ "echasnovski/mini.animate", commit = "320fb35460238c436407cd779f63abad98e84870" },
{ "echasnovski/mini.bufremove", commit = "1ee294a97e091d3cf967974df622c0d887890dc2" },
{ "echasnovski/mini.indentscope", commit = "1222393d9c5e8d92b913ccab6701a7164b21781c" },
{ "folke/lazy.nvim", version = "^11" },
{ "folke/neodev.nvim", version = "^3" },
{ "folke/lazydev.nvim", commit = "491452cf1ca6f029e90ad0d0368848fac717c6d2" },
{ "folke/noice.nvim", commit = "03c6a75661e68012e30b0ed81f050358b1e2233c" },
{ "folke/tokyonight.nvim", version = "^3" },
{ "folke/ts-comments.nvim", version = "^2" },
Expand Down
12 changes: 10 additions & 2 deletions lua/plugins/2-ui.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
-- -> highlight-undo [highlights]
-- -> which-key [on-screen keybinding]

local utils = require "base.utils"
local utils = require("base.utils")
local is_windows = vim.fn.has('win32') == 1 -- true if on windows
local is_android = vim.fn.isdirectory('/data') == 1 -- true if on android

Expand Down Expand Up @@ -314,7 +314,15 @@ return {
local is_disabled = not require("heirline-components.buffer").is_valid(args.buf) or
lib.condition.buffer_matches({
buftype = { "terminal", "prompt", "nofile", "help", "quickfix" },
filetype = { "NvimTree", "neo%-tree", "dashboard", "Outline", "aerial" },
filetype = {
"NvimTree",
"neo%-tree",
"dashboard",
"Outline",
"aerial",
"rnvimr",
"yazi"
},
}, args.buf)
return is_disabled
end,
Expand Down
160 changes: 140 additions & 20 deletions lua/plugins/3-dev-core.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
-- -> nvim-ts-autotag [treesitter understand html tags]
-- -> ts-comments.nvim [treesitter comments]
-- -> markdown.nvim [markdown highlights]
-- -> nvim-colorizer [hex colors]
-- -> nvim-highlight-colors [hex colors]

-- ## LSP
-- -> nvim-java [java support]
Expand All @@ -17,8 +17,8 @@
-- -> SchemaStore.nvim [mason extra schemas]
-- -> none-ls-autoload.nvim [mason package loader]
-- -> none-ls [lsp code formatting]
-- -> neodev [lsp for nvim lua api]
-- -> garbage-day [lsp garbage collector]
-- -> lazydev [lua lsp for nvim plugins]

-- ## AUTO COMPLETION
-- -> nvim-cmp [auto completion engine]
Expand Down Expand Up @@ -131,6 +131,10 @@ return {
},
},
},
config = function(_, opts)
-- calling setup() here is necessary to enable conceal and some features.
require("nvim-treesitter.configs").setup(opts)
end,
},

-- ts-comments.nvim [treesitter comments]
Expand Down Expand Up @@ -171,17 +175,11 @@ return {
},

-- [hex colors]
-- https://github.com/NvChad/nvim-colorizer.lua
-- https://github.com/brenoprata10/nvim-highlight-colors
{
"NvChad/nvim-colorizer.lua",
"brenoprata10/nvim-highlight-colors",
event = "User BaseFile",
cmd = {
"ColorizerToggle",
"ColorizerAttachToBuffer",
"ColorizerDetachFromBuffer",
"ColorizerReloadAllBuffers",
},
opts = { user_default_options = { names = false } },
cmd = { "HighlightColors" }
},

-- LSP -------------------------------------------------------------------
Expand Down Expand Up @@ -341,14 +339,6 @@ return {
end
},

-- neodev.nvim [lsp for nvim lua api]
-- https://github.com/folke/neodev.nvim
{
"folke/neodev.nvim",
ft = { "lua" },
opts = {}
},

-- garbage-day.nvim [lsp garbage collector]
-- https://github.com/zeioth/garbage-day.nvim
{
Expand All @@ -367,6 +357,134 @@ return {
}
},

-- neodev.nvim [lua lsp for nvim plugins]
-- https://github.com/folke/neodev.nvim
{
"folke/lazydev.nvim",
ft = "lua",
cmd = "LazyDev",
opts = function(_, opts)
opts.library = {
-- Any plugin you wanna have LSP autocompletion for, add it here.
-- in 'path', write the name of the plugin directory.
-- in 'mods', write the word you use to require the module.
-- in 'words' write words that trigger loading a lazydev path (optionally).
{ path = "lazy.nvim", mods = { "lazy" } },
{ path = "yazi.nvim", mods = { "yazi" } },
{ path = "project.nvim", mods = { "project_nvim", "telescope" } },
{ path = "trim.nvim", mods = { "trim" } },
{ path = "stickybuf.nvim", mods = { "stickybuf" } },
{ path = "bufremove.nvim", mods = { "mini.bufremove" } },
{ path = "smart-splits.nvim", mods = { "smart-splits" } },
{ path = "better-scape.nvim", mods = { "better_escape" } },
{ path = "toggleterm.nvim", mods = { "toggleterm" } },
{ path = "neovim-session-manager.nvim", mods = { "session_manager" } },
{ path = "nvim-spectre", mods = { "spectre" } },
{ path = "neo-tree.nvim", mods = { "neo-tree" } },
{ path = "nui.nvim", mods = { "nui" } },
{ path = "nvim-ufo", mods = { "ufo" } },
{ path = "promise-async", mods = { "promise-async" } },
{ path = "nvim-neoclip.lua", mods = { "neoclip", "telescope" } },
{ path = "zen-mode.nvim", mods = { "zen-mode" } },
{ path = "vim-suda", mods = { "suda" } }, -- has vimscript
{ path = "vim-matchup", mods = { "matchup", "match-up", "treesitter-matchup" } }, -- has vimscript
{ path = "hop.nvim", mods = { "hop", "hop-treesitter", "hop-yank" } },
{ path = "nvim-autopairs", mods = { "nvim-autopairs" } },
{ path = "lsp_signature", mods = { "lsp_signature" } },
{ path = "nvim-lightbulb", mods = { "nvim-lightbulb" } },
{ path = "distroupdate.nvim", mods = { "distroupdate" } },

{ path = "tokyonight.nvim", mods = { "tokyonight" } },
{ path = "astrotheme", mods = { "astrotheme" } },
{ path = "alpha-nvim", mods = { "alpha" } },
{ path = "nvim-notify", mods = { "notify" } },
{ path = "mini.indentscope", mods = { "mini.indentscope" } },
{ path = "heirline-components.nvim", mods = { "heirline-components" } },
{ path = "telescope.nvim", mods = { "telescope" } },
{ path = "telescope-undo.nvim", mods = { "telescope", "telescope-undo" } },
{ path = "telescope-fzf-native.nvim", mods = { "telescope", "fzf_lib" } },
{ path = "dressing.nvim", mods = { "dressing" } },
{ path = "noice.nvim", mods = { "noice", "telescope" } },
{ path = "nvim-web-devicons", mods = { "nvim-web-devicons" } },
{ path = "lspkind.nvim", mods = { "lspkind" } },
{ path = "nvim-scrollbar", mods = { "scrollbar" } },
{ path = "mini.animate", mods = { "mini.animate" } },
{ path = "highlight-undo.nvim", mods = { "highlight-undo" } },
{ path = "which-key.nvim", mods = { "which-key" } },

{ path = "nvim-treesitter", mods = { "nvim-treesitter" } },
{ path = "nvim-ts-autotag", mods = { "nvim-ts-autotag" } },
{ path = "nvim-treesitter-textobjects", mods = { "nvim-treesitter", "nvim-treesitter-textobjects" } },
{ path = "ts-comments.nvim", mods = { "ts-comments" } },
{ path = "markdown.nvim", mods = { "render-markdown" } },
{ path = "nvim-highlight-colors", mods = { "nvim-highlight-colors" } },
{ path = "nvim-java", mods = { "java" } },
{ path = "nvim-lspconfig", mods = { "lspconfig" } },
{ path = "mason-lspconfig.nvim", mods = { "mason-lspconfig" } },
{ path = "mason.nvim", mods = { "mason", "mason-core", "mason-registry", "mason-vendor" } },
{ path = "mason-extra-cmds", mods = { "masonextracmds" } },
{ path = "SchemaStore.nvim", mods = { "schemastore" } },
{ path = "none-ls-autoload.nvim", mods = { "none-ls-autoload" } },
{ path = "none-ls.nvim", mods = { "null-ls" } },
{ path = "lazydev.nvim", mods = { "" } },
{ path = "garbage-day.nvim", mods = { "garbage-day" } },
{ path = "nvim-cmp", mods = { "cmp" } },
{ path = "cmp_luasnip", mods = { "cmp_luasnip" } },
{ path = "cmp-buffer", mods = { "cmp_buffer" } },
{ path = "cmp-path", mods = { "cmp_path" } },
{ path = "cmp-nvim-lsp", mods = { "cmp_nvim_lsp" } },

{ path = "LuaSnip", mods = { "luasnip" } },
{ path = "friendly-snippets", mods = { "snippets" } }, -- has vimscript
{ path = "NormalSnippets", mods = { "snippets" } }, -- has vimscript
{ path = "telescope-luasnip.nvim", mods = { "telescop" } },
{ path = "gitsigns.nvim", mods = { "gitsigns" } },
{ path = "vim-fugitive", mods = { "fugitive" } }, -- has vimscript
{ path = "aerial.nvim", mods = { "aerial", "telescope", "lualine", "resession" } },
{ path = "litee.nvim", mods = { "litee" } },
{ path = "litee-calltree.nvim", mods = { "litee" } },
{ path = "dooku.nvim", mods = { "dooku" } },
{ path = "markdown-preview.nvim", mods = { "mkdp" } }, -- has vimscript
{ path = "markmap.nvim", mods = { "markmap" } },
{ path = "neural", mods = { "neural" } },
{ path = "guess-indent.nvim", mods = { "guess-indent" } },
{ path = "compiler.nvim", mods = { "compiler" } },
{ path = "overseer.nvim", mods = { "overseer", "lualine", "neotest", "resession", "cmp_overseer" } },
{ path = "nvim-dap", mods = { "dap" } },
{ path = "nvim-nio", mods = { "nio" } },
{ path = "nvim-dap-ui", mods = { "dapui" } },
{ path = "cmp-dap", mods = { "cmp_dap" } },
{ path = "mason-nvim-dap.nvim", mods = { "mason-nvim-dap" } },
{ path = "one-small-step-for-vimkind", mods = { "osv" } },
{ path = "neotest-dart", mods = { "neotest-dart" } },
{ path = "neotest-dotnet", mods = { "neotest-dotnet" } },
{ path = "neotest-elixir", mods = { "neotest-elixir" } },
{ path = "neotest-golang", mods = { "neotest-golang" } },
{ path = "neotest-java", mods = { "neotest-java" } },
{ path = "neotest-jest", mods = { "neotest-jest" } },
{ path = "neotest-phpunit", mods = { "neotest-phpunit" } },
{ path = "neotest-python", mods = { "neotest-python" } },
{ path = "neotest-rust", mods = { "neotest-rust" } },
{ path = "neotest-zig", mods = { "neotest-zig" } },
{ path = "nvim-coverage.nvim", mods = { "coverage" } },
{ path = "gutentags_plus", mods = { "gutentags_plus" } }, -- has vimscript
{ path = "vim-gutentags", mods = { "vim-gutentags" } }, -- has vimscript

-- To make it work exactly like neodev, you can add all plugins
-- without conditions instead like this but it will load slower
-- on startup and consume ~1 Gb RAM:
-- vim.fn.stdpath "data" .. "/lazy",

-- You can also add libs.
{ path = "luvit-meta/library", mods = { "vim%.uv" } },
}
end,
specs = {
{ "Bilal2453/luvit-meta", lazy = true },
-- { "folke/neodev.nvim", lazy = true}
},
},

-- AUTO COMPLETION --------------------------------------------------------
-- Auto completion engine [autocompletion engine]
-- https://github.com/hrsh7th/nvim-cmp
Expand All @@ -376,7 +494,7 @@ return {
"saadparwaiz1/cmp_luasnip",
"hrsh7th/cmp-buffer",
"hrsh7th/cmp-path",
"hrsh7th/cmp-nvim-lsp"
"hrsh7th/cmp-nvim-lsp",
},
event = "InsertEnter",
opts = function()
Expand Down Expand Up @@ -419,6 +537,7 @@ return {
},
duplicates = {
nvim_lsp = 1,
lazydev = 1,
luasnip = 1,
cmp_tabnine = 1,
buffer = 1,
Expand Down Expand Up @@ -507,6 +626,7 @@ return {
},
sources = cmp.config.sources {
{ name = "nvim_lsp", priority = 1000 },
{ name = "lazydev", priority = 850 },
{ name = "luasnip", priority = 750 },
{ name = "buffer", priority = 500 },
{ name = "path", priority = 250 },
Expand Down