diff options
Diffstat (limited to 'config/.config/nvim/after')
-rw-r--r-- | config/.config/nvim/after/plugin/colors.lua | 15 | ||||
-rw-r--r-- | config/.config/nvim/after/plugin/lsp.lua | 70 | ||||
-rw-r--r-- | config/.config/nvim/after/plugin/telescope.lua | 4 | ||||
-rw-r--r-- | config/.config/nvim/after/plugin/treesitter.lua | 22 |
4 files changed, 111 insertions, 0 deletions
diff --git a/config/.config/nvim/after/plugin/colors.lua b/config/.config/nvim/after/plugin/colors.lua new file mode 100644 index 0000000..f01a945 --- /dev/null +++ b/config/.config/nvim/after/plugin/colors.lua @@ -0,0 +1,15 @@ +function ColorItNiceAndGood(color) + + ---- Available Coloschemes + -- rose-pine + -- catppuccin, catppuccin-latte, catppuccin-frappe, catppuccin-macchiato, catppuccin-mocha + + color = color or "catppuccin" + vim.cmd.colorscheme(color) + + --- Transparency + --vim.api.nvim_set_hl(0, "Normal", {bg = "none"}) + --vim.api.nvim_set_hl(0, "NormalFloat", {bg = "none"}) +end + +ColorItNiceAndGood() diff --git a/config/.config/nvim/after/plugin/lsp.lua b/config/.config/nvim/after/plugin/lsp.lua new file mode 100644 index 0000000..58546de --- /dev/null +++ b/config/.config/nvim/after/plugin/lsp.lua @@ -0,0 +1,70 @@ + local lsp = require('lsp-zero').preset({ + name = 'minimal', + set_lsp_keymaps = true, + manage_nvim_cmp = true, + suggest_lsp_servers = false, +}) + +-- (Optional) Configure lua language server for neovim +lsp.nvim_workspace() + +lsp.ensure_installed = ({ + "quick_lint_js", + "html-lsp", + "css-lsp"; + "lua_ls", + "clangd", + "python-lsp-server", +}) + + + +---------------------- +-- Completion stuff -- +---------------------- + +lsp.setup_nvim_cmp({ + preselect = 'none', + completion = { + autocomplete = false, + completeopt = 'menu,menuone,noinsert,noselect', + }, +}) + + + +local cmp = require('cmp') +local cmp_select = {behavior = cmp.SelectBehavior.Select} +local cmp_mappings = lsp.defaults.cmp_mappings({ + ['<C-p>'] = cmp.mapping.select_prev_item(cmp_select), + ['<C-n>'] = cmp.mapping.select_next_item(cmp_select), + ['<C-y>'] = cmp.mapping.confirm( {select = true} ), + ['<C-Space>'] = cmp.mapping.complete(), +}) + + + + + +lsp.set_preferences({ + sign_icons = { } +}) + +lsp.setup() + + + + +------------------------ +-- Disable Diagnostics - +------------------------ + +vim.diagnostic.config({ + virtual_text = false, + signs = false, + update_in_insert = false, + underline = false, + severity_sort = false, + float = false, +}) + diff --git a/config/.config/nvim/after/plugin/telescope.lua b/config/.config/nvim/after/plugin/telescope.lua new file mode 100644 index 0000000..1143e66 --- /dev/null +++ b/config/.config/nvim/after/plugin/telescope.lua @@ -0,0 +1,4 @@ +local builtin = require('telescope.builtin') +vim.keymap.set('n', '<leader>pf', builtin.find_files, {}) +vim.keymap.set('n', '<C-p>', builtin.git_files, {}) +vim.keymap.set('n', '<C-s>', builtin.current_buffer_fuzzy_find, {}) diff --git a/config/.config/nvim/after/plugin/treesitter.lua b/config/.config/nvim/after/plugin/treesitter.lua new file mode 100644 index 0000000..8a087f7 --- /dev/null +++ b/config/.config/nvim/after/plugin/treesitter.lua @@ -0,0 +1,22 @@ +require'nvim-treesitter.configs'.setup { + -- A list of parser names, or "all" (the five listed parsers should always be installed) + ensure_installed = { "help", "javascript", "python", "lua", "vim", "bash", "css", "html", "c", "make" }, + + -- Install parsers synchronously (only applied to `ensure_installed`) + sync_install = false, + + -- Automatically install missing parsers when entering buffer + -- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally + auto_install = true, + + + highlight = { + enable = true, + + -- Setting this to true will run `:h syntax` and tree-sitter at the same time. + -- Set this to `true` if you depend on 'syntax' being enabled (like for indentation). + -- Using this option may slow down your editor, and you may see some duplicate highlights. + -- Instead of true it can also be a list of languages + additional_vim_regex_highlighting = false, + }, +} |