mirror of
https://github.com/NotAShelf/nvf.git
synced 2026-02-05 11:25:52 +00:00
feat(smartcolumn): custom setup opts
This commit is contained in:
parent
80fee9dae7
commit
5ea6272bee
3 changed files with 30 additions and 27 deletions
|
|
@ -4,9 +4,8 @@
|
|||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkIf;
|
||||
inherit (lib.strings) concatStringsSep;
|
||||
inherit (lib.nvim.lua) attrsetToLuaTable;
|
||||
inherit (lib.nvim.dag) entryAnywhere;
|
||||
inherit (lib.nvim.lua) toLuaObject;
|
||||
|
||||
cfg = config.vim.ui.smartcolumn;
|
||||
in {
|
||||
|
|
@ -15,13 +14,7 @@ in {
|
|||
startPlugins = ["smartcolumn"];
|
||||
|
||||
vim.luaConfigRC.smartcolumn = entryAnywhere ''
|
||||
require("smartcolumn").setup({
|
||||
colorcolumn = "${toString cfg.showColumnAt}",
|
||||
-- { "help", "text", "markdown", "NvimTree", "alpha"},
|
||||
disabled_filetypes = { ${concatStringsSep ", " (map (x: "\"" + x + "\"") cfg.disabledFiletypes)} },
|
||||
custom_colorcolumn = ${attrsetToLuaTable cfg.columnAt.languages},
|
||||
scope = "file",
|
||||
})
|
||||
require("smartcolumn").setup(${toLuaObject cfg.setupOpts})
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue