From 34bdca17d298c5762219649b238e8f1ca0689352 Mon Sep 17 00:00:00 2001 From: siduck Date: Mon, 10 Apr 2023 10:05:05 +0530 Subject: [PATCH] clean up --- lua/core/bootstrap.lua | 21 +++------------------ lua/core/default_config.lua | 18 ++++-------------- 2 files changed, 7 insertions(+), 32 deletions(-) diff --git a/lua/core/bootstrap.lua b/lua/core/bootstrap.lua index 865f3b4..b00fc09 100644 --- a/lua/core/bootstrap.lua +++ b/lua/core/bootstrap.lua @@ -25,24 +25,9 @@ M.lazy = function(install_path) -- install plugins require "plugins" - vim.api.nvim_buf_delete(0, { force = true }) -- close lazy window - ---------- mason packages ------------- - vim.schedule(function() - vim.cmd "MasonInstallAll" - local packages = table.concat(vim.g.mason_binaries_list, " ") - - require("mason-registry"):on("package:install:success", function(pkg) - packages = string.gsub(packages, pkg.name:gsub("%-", "%%-"), "") -- rm package name - - if packages:match "%S" == nil then - vim.schedule(function() - vim.api.nvim_buf_delete(0, { force = true }) - M.echo "Now please read the docs at nvchad.com!! 󰕹 󰱬" - end) - end - end) - end) + -- mason packages & show post_boostrap screen + require "nvchad.post_bootstrap"() end M.gen_chadrc_template = function() @@ -60,7 +45,7 @@ M.gen_chadrc_template = function() vim.fn.mkdir(path, "p") local file = io.open(path .. "chadrc.lua", "w") - file:write "local M = {}\n M.ui = {theme = 'onedark'}\n return M" + file:write "---@type ChadrcConfig \n local M = {}\n M.ui = {theme = 'onedark'}\n return M" file:close() end end diff --git a/lua/core/default_config.lua b/lua/core/default_config.lua index 0f5ce56..61fa715 100644 --- a/lua/core/default_config.lua +++ b/lua/core/default_config.lua @@ -1,12 +1,7 @@ --- Chadrc overrides this file - local M = {} M.options = { - nvChad = { - update_url = "https://github.com/NvChad/NvChad", - update_branch = "v2.0", - }, + nvchad_branch = "v2.0", } M.ui = { @@ -29,9 +24,7 @@ M.ui = { selected_item_bg = "colored", -- colored / simple }, - telescope = { - style = "borderless", -- borderless / bordered - }, + telescope = { style = "borderless" }, -- borderless / bordered ------------------------------- nvchad_ui modules ----------------------------- statusline = { @@ -76,9 +69,7 @@ M.ui = { }, }, - cheatsheet = { - theme = "grid", -- simple/grid - }, + cheatsheet = { theme = "grid" }, -- simple/grid lsp = { -- show function signatures i.e args as you type @@ -89,11 +80,10 @@ M.ui = { }, } -M.plugins = "" -- path i.e "custom.plugins" -> custom/plugins.lua only and not custom/plugins/init.lua!!!! +M.plugins = "" -- path i.e "custom.plugins", so make custom/plugins.lua file M.lazy_nvim = require "plugins.configs.lazy_nvim" -- config for lazy.nvim startup options --- these are default mappings, check core.mappings for table structure M.mappings = {} return M