.dotfiles/config/nvim/init.lua
Matthew Fisher 15ea176db9 Updated nvim config with autoclose
Added tab config (4 spaces)
2024-09-02 11:14:26 -05:00

57 lines
1.5 KiB
Lua

local ensure_packer = function()
local fn = vim.fn
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
if fn.empty(fn.glob(install_path)) > 0 then
fn.system({'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path})
vim.cmd [[packadd packer.nvim]]
return true
end
return false
end
require('config')
require('plugins')
local packer_bootstrap = ensure_packer()
vim.opt.clipboard = 'unnamed'
return require('packer').startup(function(use)
use 'wbthomason/packer.nvim'
use { "catppuccin/nvim", as = "catppuccin" }
use ({'m4xshen/autoclose.nvim'})
-- TreeSitter
use ('nvim-treesitter/nvim-treesitter', { run = ":TSUpdate"})
use {'nvim-telescope/telescope.nvim', tag = '0.1.8', requires = { {'nvim-lua/plenary.nvim'} }}
use ({"williamboman/mason.nvim"})
use ({"williamboman/mason-lspconfig.nvim"})
use ({'VonHeikemen/lsp-zero.nvim', branch = 'v4.x'})
use ({'neovim/nvim-lspconfig'})
use ({'hrsh7th/nvim-cmp'})
use ({'hrsh7th/cmp-nvim-lsp'})
use ({"L3MON4D3/LuaSnip"})
use ({"rafamadriz/friendly-snippets"})
use {
'hrsh7th/nvim-cmp',
config = function ()
require'cmp'.setup {
snippet = {
expand = function(args)
require'luasnip'.lsp_expand(args.body)
end
},
}
end
}
use { 'saadparwaiz1/cmp_luasnip' }
-- Automatically set up your configuration after cloning packer.nvim
-- Put this at the end after all plugins
if packer_bootstrap then
require('packer').sync()
end
end)