diff options
author | aktersnurra <gustaf.rydholm@gmail.com> | 2022-10-29 18:19:38 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-29 18:19:38 +0200 |
commit | 2951af7bbd839ebef25e33f8bd01bd5c501f76c8 (patch) | |
tree | f1829cc7af1fc0c5900b23055d12bb0446962cfb /lua/no-clown-fiesta/init.lua | |
parent | 3234b296d7f70cc78ac37a51fc3cff28e7871812 (diff) |
Update how options and colorscheme is set (#12)
* Update loading of colorscheme
* Fix typo
* Fix setting of style
* Fix highlighting
* Unpack style
* Add empty table if props are nil
* Fix concat of tables
* Fix typo
* Update settings
* Add call set in settings
* Add deep extend
* Remove style field
* Update README
BREAKING CHANGE: updates how the colorscheme is set and the structure of the options table
Diffstat (limited to 'lua/no-clown-fiesta/init.lua')
-rw-r--r-- | lua/no-clown-fiesta/init.lua | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/lua/no-clown-fiesta/init.lua b/lua/no-clown-fiesta/init.lua index 170a4d2..1cfc291 100644 --- a/lua/no-clown-fiesta/init.lua +++ b/lua/no-clown-fiesta/init.lua @@ -1,10 +1,15 @@ local M = {} -function M.setup(opts) +function M.setup(options) local settings = require "no-clown-fiesta.settings" - if opts then - opts = settings.set(opts) + if options then + settings.set(options) end +end + +function M.load() + local settings = require "no-clown-fiesta.settings" + local options = settings.options vim.api.nvim_command "hi clear" if vim.fn.exists "syntax_on" then @@ -17,7 +22,7 @@ function M.setup(opts) local util = require "no-clown-fiesta.util" local palette = require "no-clown-fiesta.palette" - local highlights = require("no-clown-fiesta.highlights").highlight(palette, opts) + local highlights = require("no-clown-fiesta.highlights").highlight(palette, options) local alpha = require("no-clown-fiesta.highlight-group.alpha").highlight(palette) local git = require("no-clown-fiesta.highlight-group.git").highlight(palette) @@ -40,7 +45,7 @@ function M.setup(opts) ) local treesitter = require("no-clown-fiesta.highlight-group.treesitter").highlight( palette, - opts + options ) local whichkey = require("no-clown-fiesta.highlight-group.whichkey").highlight( palette |