diff options
author | Gustaf Rydholm <gustaf.rydholm@gmail.com> | 2022-07-29 17:19:06 +0200 |
---|---|---|
committer | Gustaf Rydholm <gustaf.rydholm@gmail.com> | 2022-07-29 17:19:06 +0200 |
commit | 6859908ddee41f7b0121f3c2e3ef2262875291ba (patch) | |
tree | 1108474a0c51bd299dba9b3e469b0c4af72c9aab /lua/no-clown-fiesta/init.lua | |
parent | da502c2571b710791b29c82a77cbe577791b14df (diff) |
Refactoradd/config
Diffstat (limited to 'lua/no-clown-fiesta/init.lua')
-rw-r--r-- | lua/no-clown-fiesta/init.lua | 94 |
1 files changed, 52 insertions, 42 deletions
diff --git a/lua/no-clown-fiesta/init.lua b/lua/no-clown-fiesta/init.lua index b66b1c5..942f530 100644 --- a/lua/no-clown-fiesta/init.lua +++ b/lua/no-clown-fiesta/init.lua @@ -1,47 +1,57 @@ -vim.api.nvim_command "hi clear" -if vim.fn.exists "syntax_on" then - vim.api.nvim_command "syntax reset" -end -vim.o.background = "dark" -vim.o.termguicolors = true -vim.g.colors_name = "no-clown-fiesta" +local M = {} + +function M.setup(opts) + local settings = require "no-clown-fiesta.settings" + if opts then + opts = settings.set(opts) + end -local util = require "no-clown-fiesta.util" -C = require "no-clown-fiesta.palette" -Config = require "no-clown-fiesta.config" + vim.api.nvim_command "hi clear" + if vim.fn.exists "syntax_on" then + vim.api.nvim_command "syntax reset" + end -local Alpha = require "no-clown-fiesta.Alpha" -local Git = require "no-clown-fiesta.Git" -local Hop = require "no-clown-fiesta.Hop" -local highlights = require "no-clown-fiesta.highlights" -local Lir = require "no-clown-fiesta.Lir" -local LSP = require "no-clown-fiesta.LSP" -local markdown = require "no-clown-fiesta.markdown" -local Neogit = require "no-clown-fiesta.Neogit" -local NvimTree = require "no-clown-fiesta.NvimTree" -local NvimCmp = require "no-clown-fiesta.NvimCmp" -local StatusLine = require "no-clown-fiesta.StatusLine" -local Telescope = require "no-clown-fiesta.Telescope" -local Treesitter = require "no-clown-fiesta.Treesitter" -local Whichkey = require "no-clown-fiesta.Whichkey" + vim.o.background = "dark" + vim.o.termguicolors = true + vim.g.colors_name = "no-clown-fiesta" -local skeletons = { - Alpha, - Git, - Hop, - highlights, - Lir, - LSP, - markdown, - Neogit, - NvimTree, - NvimCmp, - StatusLine, - Telescope, - Treesitter, - Whichkey, -} + local util = require "no-clown-fiesta.util" + local palette = require "no-clown-fiesta.palette" + local alpha = require("no-clown-fiesta.alpha").highlight(palette) + local git = require("no-clown-fiesta.git").highlight(palette) + local hop = require("no-clown-fiesta.hop").highlight(palette) + local highlights = require("no-clown-fiesta.highlights").highlight(palette, opts) + local lir = require("no-clown-fiesta.Lir").highlight(palette) + local lsp = require("no-clown-fiesta.LSP").highlight(palette) + local markdown = require("no-clown-fiesta.markdown").highlight(palette) + local neogit = require("no-clown-fiesta.neogit").highlight(palette) + local nvimtree = require("no-clown-fiesta.nvim-tree").highlight(palette) + local nvimcmp = require("no-clown-fiesta.nvim-cmp").highlight(palette) + local statusline = require("no-clown-fiesta.statusline").highlight(palette) + local telescope = require("no-clown-fiesta.telescope").highlight(palette) + local treesitter = require("no-clown-fiesta.treesitter").highlight(palette, opts) + local whichkey = require("no-clown-fiesta.whichkey").highlight(palette) -for _, skeleton in ipairs(skeletons) do - util.initialise(skeleton) + local skeletons = { + alpha, + git, + hop, + highlights, + lir, + lsp, + markdown, + neogit, + nvimtree, + nvimcmp, + statusline, + telescope, + treesitter, + whichkey, + } + + for _, skeleton in ipairs(skeletons) do + util.initialise(skeleton) + end end + +return M |