mirror of
https://github.com/gabehf/base46.git
synced 2026-03-16 02:35:56 -07:00
put syntax & treesitter highlights in the same file
This commit is contained in:
parent
add8e21a0c
commit
fc44f0372c
3 changed files with 8 additions and 6 deletions
|
|
@ -120,12 +120,13 @@ M.saveStr_to_cache = function(filename, tb)
|
||||||
end
|
end
|
||||||
|
|
||||||
M.compile = function()
|
M.compile = function()
|
||||||
|
|
||||||
-- All integration modules, each file returns a table
|
-- All integration modules, each file returns a table
|
||||||
local hl_files = vim.g.base46_custom_path or vim.fn.stdpath "data" .. "/lazy/base46/lua/base46/integrations"
|
local hl_files = vim.g.base46_custom_path or vim.fn.stdpath "data" .. "/lazy/base46/lua/base46/integrations"
|
||||||
|
|
||||||
for _, file in ipairs(vim.fn.readdir(hl_files)) do
|
for _, file in ipairs(vim.fn.readdir(hl_files)) do
|
||||||
-- skip caching statusline file as its done in defaults file
|
-- skip caching some files
|
||||||
if file ~= "statusline" then
|
if file ~= "statusline" or file ~= "treesitter" then
|
||||||
local filename = vim.fn.fnamemodify(file, ":r")
|
local filename = vim.fn.fnamemodify(file, ":r")
|
||||||
M.saveStr_to_cache(filename, M.load_highlight(filename))
|
M.saveStr_to_cache(filename, M.load_highlight(filename))
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -253,8 +253,6 @@ local defaults = {
|
||||||
|
|
||||||
-- merge statusilne & hl_add tables!
|
-- merge statusilne & hl_add tables!
|
||||||
local merge_tb = require("base46").merge_tb
|
local merge_tb = require("base46").merge_tb
|
||||||
|
|
||||||
defaults = merge_tb(defaults, require("base46").load_highlight "statusline")
|
defaults = merge_tb(defaults, require("base46").load_highlight "statusline")
|
||||||
defaults = merge_tb(defaults, require("core.utils").load_config().ui.hl_add)
|
|
||||||
|
|
||||||
return defaults
|
return merge_tb(defaults, require("core.utils").load_config().ui.hl_add)
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
local theme = require("base46").get_theme_tb "base_16"
|
local theme = require("base46").get_theme_tb "base_16"
|
||||||
|
|
||||||
return {
|
local syntax = {
|
||||||
Boolean = {
|
Boolean = {
|
||||||
fg = theme.base09,
|
fg = theme.base09,
|
||||||
},
|
},
|
||||||
|
|
@ -114,3 +114,6 @@ return {
|
||||||
fg = theme.base0A,
|
fg = theme.base0A,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
local merge_tb = require("base46").merge_tb
|
||||||
|
return merge_tb(syntax, require("base46").load_highlight "treesitter")
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue