local fn = vim.fn -- Automatically install packer local install_path = fn.stdpath "data" .. "/site/pack/packer/start/packer.nvim" if fn.empty(fn.glob(install_path)) > 0 then PACKER_BOOTSTRAP = fn.system { "git", "clone", "--depth", "1", "https://github.com/wbthomason/packer.nvim", install_path, } print "Installing packer close and reopen Neovim..." vim.cmd [[packadd packer.nvim]] end -- Autocommand that reloads neovim whenever you save the plugins.lua file vim.cmd [[ augroup packer_user_config autocmd! autocmd BufWritePost plugins.lua source | PackerSync augroup end ]] -- Use a protected call so we don't error out on first use local status_ok, packer = pcall(require, "packer") if not status_ok then return end -- Have packer use a popup window packer.init { display = { open_fn = function() return require("packer.util").float { border = "rounded" } end, }, } return packer.startup(function(use) -- Packer can manage itself use 'wbthomason/packer.nvim' use 'morhetz/gruvbox' -- Status line use { 'hoob3rt/lualine.nvim', config = [[require('config.lualine')]], } use 'tpope/vim-fugitive' use 'mhinz/vim-signify' use 'tpope/vim-surround' use 'tpope/vim-repeat' use { 'neovim/nvim-lspconfig', requires = { "hrsh7th/cmp-nvim-lsp", 'williamboman/nvim-lsp-installer', } } use { 'hrsh7th/nvim-cmp', event = 'InsertEnter', config = [[require('completion')]], requires = { 'hrsh7th/vim-vsnip', -- 'hrsh7th/vim-vsnip-integ', -- 'rafamadriz/friendly-snippets', }, } use {'hrsh7th/cmp-vsnip', after = 'nvim-cmp'} use {'hrsh7th/cmp-buffer', after = 'nvim-cmp'} use {'hrsh7th/cmp-path', after = 'nvim-cmp'} use {'hrsh7th/cmp-nvim-lsp', after = 'nvim-cmp'} -- use {'f3fora/cmp-spell', after = 'nvim-cmp'} -- for formatters and linters use { "jose-elias-alvarez/null-ls.nvim", config = [[require('config.null-ls')]] } use 'nvim-lua/popup.nvim' use { 'nvim-telescope/telescope.nvim', config = [[require('config.telescope')]], requires = { 'nvim-lua/plenary.nvim'} } use {'nvim-telescope/telescope-fzf-native.nvim', run = 'make' } use { 'lervag/vimtex', config = [[require('config.vimtex')]], } -- Highlight on Yank use 'machakann/vim-highlightedyank' -- Autoclose parenthesis -- use 'jiangmiao/auto-pairs' use { 'windwp/nvim-autopairs', config = [[ require('config.autopairs') ]] } use 'kyazdani42/nvim-web-devicons' use { 'xolox/vim-notes', config = [[require('config.notes')]], requires = { 'xolox/vim-misc', } } use 'christoomey/vim-tmux-navigator' use { 'nvim-treesitter/nvim-treesitter', config=[[require('config.treesitter')]], run = ':TSUpdate', } use { 'norcalli/nvim-colorizer.lua', config = [[require('config.colorizer')]], } if PACKER_BOOTSTRAP then require("packer").sync() end end)