mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-02-24 12:28:32 +00:00
neorg: setupOpts setup correctly
This commit is contained in:
parent
eb983c8560
commit
e1d292aac3
2 changed files with 3 additions and 40 deletions
|
@ -28,24 +28,7 @@ in {
|
|||
};
|
||||
|
||||
pluginRC.neorg = entryAnywhere ''
|
||||
-- Treesitter configuration
|
||||
require('nvim-treesitter.configs').setup {
|
||||
|
||||
-- If TS highlights are not enabled at all, or disabled via `disable` prop,
|
||||
-- highlighting will fallback to default Vim syntax highlighting
|
||||
highlight = {
|
||||
enable = true,
|
||||
-- Required for spellcheck, some LaTex highlights and
|
||||
-- code block highlights that do not have ts grammar
|
||||
additional_vim_regex_highlighting = {'neorg'},
|
||||
},
|
||||
}
|
||||
|
||||
require('neorg').setup{
|
||||
${cfg.setupOpts}
|
||||
}
|
||||
|
||||
vim.wo.conceallevel = 2
|
||||
require('neorg').setup(${toLuaObject cfg.setupOpts})
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,33 +4,13 @@
|
|||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.options) mkEnableOption mkOption;
|
||||
inherit (lib.types) lines;
|
||||
inherit (lib.options) mkEnableOption;
|
||||
inherit (lib.nvim.types) mkGrammarOption mkPluginSetupOption;
|
||||
in {
|
||||
options.vim.notes.neorg = {
|
||||
enable = mkEnableOption "neorg: Neovim plugin for Neorg";
|
||||
|
||||
setupOpts = mkOption {
|
||||
type = lines;
|
||||
default = ''
|
||||
|
||||
load = {
|
||||
['core.defaults'] = {}, -- Loads default behaviour
|
||||
['core.concealer'] = {}, -- Adds pretty icons to your documents
|
||||
['core.export'] = {}, -- Adds export options
|
||||
['core.integrations.telescope'] = {}, -- Telescope integration
|
||||
['core.dirman'] = { -- Manages Neorg workspaces
|
||||
config = {
|
||||
workspaces = {
|
||||
notes = '~/Documents/neorg',
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
'';
|
||||
description = "Neorg configuration";
|
||||
};
|
||||
setupOpts = mkPluginSetupOption "Neorg" {};
|
||||
|
||||
treesitter = {
|
||||
enable = mkEnableOption "Neorg treesitter" // {default = config.vim.languages.enableTreesitter;};
|
||||
|
|
Loading…
Add table
Reference in a new issue