fix: packpath error on first run (#139)

packadd command not working because it was not installed on first run.

Co-authored-by: Christian Chiarulli <chrisatmachine@gmail.com>
This commit is contained in:
michaelslec 2021-03-18 22:01:39 -07:00 committed by GitHub
parent a7c77a04b5
commit ab661fb3b8
WARNING! Although there is a key with this ID in the database it does not verify this commit! This commit is SUSPICIOUS.
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,3 +1,5 @@
vim.cmd [[packadd packer.nvim]]
local execute = vim.api.nvim_command local execute = vim.api.nvim_command
local fn = vim.fn local fn = vim.fn
@ -8,8 +10,6 @@ if fn.empty(fn.glob(install_path)) > 0 then
execute 'packadd packer.nvim' execute 'packadd packer.nvim'
end end
vim.cmd [[packadd packer.nvim]]
vim.cmd 'autocmd BufWritePost plugins.lua PackerCompile' -- Auto compile when there are changes in plugins.lua vim.cmd 'autocmd BufWritePost plugins.lua PackerCompile' -- Auto compile when there are changes in plugins.lua
return require('packer').startup(function(use) return require('packer').startup(function(use)