diff --git a/docs/manual/release-notes/rl-0.9.md b/docs/manual/release-notes/rl-0.9.md index 929f442c..c38d2421 100644 --- a/docs/manual/release-notes/rl-0.9.md +++ b/docs/manual/release-notes/rl-0.9.md @@ -138,6 +138,9 @@ [Tombi](https://tombi-toml.github.io/tombi/) language server, linter, and formatter. +- Added [hlargs.nvim](https://github.com/m-demare/hlargs.nvim) support as + `visuals.hlargs-nvim`. + [Machshev](https://github.com/machshev): - Added `ruff` and `ty` LSP support for Python under `programs.python`. diff --git a/modules/plugins/visuals/default.nix b/modules/plugins/visuals/default.nix index 3a44aa45..3caf6e32 100644 --- a/modules/plugins/visuals/default.nix +++ b/modules/plugins/visuals/default.nix @@ -11,6 +11,7 @@ in { ./cinnamon-nvim ./fidget-nvim ./highlight-undo + ./hlargs-nvim ./indent-blankline ./nvim-cursorline ./nvim-scrollbar diff --git a/modules/plugins/visuals/hlargs-nvim/config.nix b/modules/plugins/visuals/hlargs-nvim/config.nix new file mode 100644 index 00000000..5dcb4a19 --- /dev/null +++ b/modules/plugins/visuals/hlargs-nvim/config.nix @@ -0,0 +1,18 @@ +{ + config, + lib, + ... +}: let + inherit (lib.modules) mkIf; + inherit (lib.nvim.dag) entryAnywhere; + inherit (lib.nvim.lua) toLuaObject; + cfg = config.vim.visuals.hlargs-nvim; +in { + vim = mkIf cfg.enable { + startPlugins = ["hlargs-nvim"]; + + pluginRC.hlargs-nvim = entryAnywhere '' + require('hlargs').setup(${toLuaObject cfg.setupOpts}) + ''; + }; +} diff --git a/modules/plugins/visuals/hlargs-nvim/default.nix b/modules/plugins/visuals/hlargs-nvim/default.nix new file mode 100644 index 00000000..0c880b9f --- /dev/null +++ b/modules/plugins/visuals/hlargs-nvim/default.nix @@ -0,0 +1,6 @@ +{ + imports = [ + ./hlargs-nvim.nix + ./config.nix + ]; +} diff --git a/modules/plugins/visuals/hlargs-nvim/hlargs-nvim.nix b/modules/plugins/visuals/hlargs-nvim/hlargs-nvim.nix new file mode 100644 index 00000000..8a7b05d8 --- /dev/null +++ b/modules/plugins/visuals/hlargs-nvim/hlargs-nvim.nix @@ -0,0 +1,9 @@ +{lib, ...}: let + inherit (lib.options) mkEnableOption; + inherit (lib.nvim.types) mkPluginSetupOption; +in { + options.vim.visuals.hlargs-nvim = { + enable = mkEnableOption "hlargs-nvim"; + setupOpts = mkPluginSetupOption "hlargs-nvim" {}; + }; +} diff --git a/npins/sources.json b/npins/sources.json index 824dac04..5d0da66a 100644 --- a/npins/sources.json +++ b/npins/sources.json @@ -708,6 +708,19 @@ "url": "https://github.com/tzachar/highlight-undo.nvim/archive/ee32e12693d70e66f954d09a504a7371d110fc27.tar.gz", "hash": "sha256-yU4i3uPI7qghxdevOuqzxu8gIol6pxgd7TIY6vnyfiU=" }, + "hlargs-nvim": { + "type": "Git", + "repository": { + "type": "GitHub", + "owner": "m-demare", + "repo": "hlargs.nvim" + }, + "branch": "main", + "submodules": false, + "revision": "0b29317c944fb1f76503ce4540d6dceffbb5ccd2", + "url": "https://github.com/m-demare/hlargs.nvim/archive/0b29317c944fb1f76503ce4540d6dceffbb5ccd2.tar.gz", + "hash": "sha256-WjmVefR0qk2ANWgyHSuYMTuCfzlVTF7tqzAL+uatKkc=" + }, "hop.nvim": { "type": "GitRelease", "repository": {