diff --git a/docs/release-notes/rl-0.8.md b/docs/release-notes/rl-0.8.md index 5914df92..c0d4952e 100644 --- a/docs/release-notes/rl-0.8.md +++ b/docs/release-notes/rl-0.8.md @@ -510,3 +510,8 @@ - Add inline typst concealing support under `vim.languages.typst` using [typst-concealer]. + +[mugaizzo](https://github.com/mugaizzo): + +- Add [VimTeX](https://github.com/lervag/vimtex) plugin in `vim.latex.vimtex` with + `enable`. VimTeX options are set using global options `vim.globals.vimtex_OPTION`. diff --git a/modules/plugins/latex/vimtex/config.nix b/modules/plugins/latex/vimtex/config.nix index 8e26e9df..bc6e7cee 100644 --- a/modules/plugins/latex/vimtex/config.nix +++ b/modules/plugins/latex/vimtex/config.nix @@ -4,18 +4,10 @@ ... }: let inherit (lib.modules) mkIf; - # inherit (lib.nvim.dag) entryAnywhere; - # inherit (lib.nvim.lua) toLuaObject; cfg = config.vim.latex.vimtex; in { config = mkIf cfg.enable { vim.startPlugins = ["vimtex"]; - - # vim.pluginRC.vimtex = entryAnywhere '' - # -- Description of each option can be found in https://github.com/lervag/vimtex - # -- Current nvf options are minimal, contribute your needed options - # -- require("vimtex").setup(${toLuaObject cfg.setupOpts}) - # ''; }; } diff --git a/modules/plugins/latex/vimtex/vimtex.nix b/modules/plugins/latex/vimtex/vimtex.nix index 1fd96b13..1bfa5cde 100644 --- a/modules/plugins/latex/vimtex/vimtex.nix +++ b/modules/plugins/latex/vimtex/vimtex.nix @@ -4,7 +4,11 @@ inherit (lib.nvim.types) mkPluginSetupOption; in { options.vim.latex.vimtex = { - enable = mkEnableOption "VimTeX is a modern Vim and Neovim filetype and syntax plugin for LaTeX files."; + enable = mkEnableOption '' + VimTeX is a modern Vim and Neovim filetype and syntax plugin for LaTeX files. + + VimTeX options are under vim.global.vimtex_OPTION + ''; setupOpts = mkPluginSetupOption "vimtex" { vimtex_view_method = mkOption {