Skip to content

Commit

Permalink
Merge pull request #227 from FrothyMarrow/lua-packages
Browse files Browse the repository at this point in the history
wrapper: provide option to wrap neovim with extra lua packages
  • Loading branch information
NotAShelf authored Feb 17, 2024
2 parents cd4d0cd + 949a60c commit f7bd0ff
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 0 deletions.
4 changes: 4 additions & 0 deletions docs/release-notes/rl-0.6.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,7 @@ Release notes for release 0.6
[elijahimmer](https://github.com/elijahimmer)

- Added rose-pine theme

[frothymarrow](https://github.com/frothymarrow)

- Added option `vim.luaPackages` to wrap neovim with extra Lua packages.
8 changes: 8 additions & 0 deletions modules/core/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,14 @@ in {
}'';
};

luaPackages = mkOption {
type = types.listOf types.str;
default = [];
description = ''
List of lua packages to install.
'';
};

globals = mkOption {
default = {};
description = "Set containing global variable values";
Expand Down
4 changes: 4 additions & 0 deletions modules/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ inputs: {

vimOptions = module.config.vim;

extraLuaPackages = ps: map (x: ps.${x}) vimOptions.luaPackages;

buildPlug = {pname, ...} @ args:
assert lib.asserts.assertMsg (pname != "nvim-treesitter") "Use buildTreesitterPlug for building nvim-treesitter.";
buildVimPlugin (args
Expand Down Expand Up @@ -59,6 +61,8 @@ inputs: {
inherit (vimOptions) viAlias;
inherit (vimOptions) vimAlias;

inherit extraLuaPackages;

configure = {
customRC = vimOptions.builtConfigRC;

Expand Down

0 comments on commit f7bd0ff

Please sign in to comment.