Files
wezterm-config/opts.lua
T
rootiest 65917d380a feat: Add user customization and refactor for readability
- Add user customization via automatically detected user.lua file
- Reorganize config options into separate files
- Reorganize plugin loaders into separate files
2024-10-04 10:11:16 -04:00

35 lines
950 B
Lua

-- ╭─────────────────────────────────────────────────────────╮
-- │ CONFIG │
-- ╰─────────────────────────────────────────────────────────╯
local opts = {}
-- Function to merge tables into opts
local function merge_into_opts(mod)
for k, v in pairs(require("config." .. mod)) do
opts[k] = v
end
end
-- List of config modules to merge
local modules = {
"colors",
"font",
"keys",
"window",
"platform",
}
-- If USERCONFIG is true, merge userconfig
if USERCONFIG then
merge_into_opts("user")
end
-- Merge all modules into opts
for _, mod in ipairs(modules) do
merge_into_opts(mod)
end
-- Return config options
return opts