fix packer bootstrapping not working

This commit is contained in:
siduck 2022-11-17 23:16:28 +05:30
parent 76f0c9bc6f
commit 3616f417e7
2 changed files with 5 additions and 3 deletions

View File

@ -16,10 +16,9 @@ if fn.empty(fn.glob(install_path)) > 0 then
os.execute("mkdir -p " .. vim.fn.stdpath "data" .. "/site/pack/base46_cache/start/compiled_themes/lua/base46_cache/") os.execute("mkdir -p " .. vim.fn.stdpath "data" .. "/site/pack/base46_cache/start/compiled_themes/lua/base46_cache/")
require("base46").compile()
-- install plugins + compile their configs -- install plugins + compile their configs
vim.cmd "packadd packer.nvim" vim.cmd "packadd packer.nvim"
require "plugins" require "plugins"
vim.cmd "PackerSync" vim.cmd "PackerSync"
@ -27,6 +26,9 @@ if fn.empty(fn.glob(install_path)) > 0 then
vim.api.nvim_create_autocmd("User", { vim.api.nvim_create_autocmd("User", {
pattern = "PackerComplete", pattern = "PackerComplete",
callback = function() callback = function()
require("base46").compile()
require("base46").load_all_highlights()
vim.cmd "bw | silent! MasonInstallAll" -- close packer window vim.cmd "bw | silent! MasonInstallAll" -- close packer window
require("packer").loader "nvim-treesitter" require("packer").loader "nvim-treesitter"
end, end,

View File

@ -29,7 +29,7 @@ local plugins = {
["NvChad/base46"] = { ["NvChad/base46"] = {
branch = "dev", branch = "dev",
config = function() config = function()
require "base46_cache.defaults" pcall(require, "base46_cache.defaults")
end, end,
}, },