Skip to content

Commit

Permalink
plugins/emmet: cosmetic refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
GaetanLepage authored and nix-infra-bot committed Jan 22, 2025
1 parent 342161b commit e60ea67
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions plugins/by-name/emmet/default.nix
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
{
lib,
helpers,
...
}:
with lib;
with lib.nixvim.plugins;
mkVimPlugin {
let
inherit (lib) types;
inherit (lib.nixvim) defaultNullOpts mkNullOrOption;
in
lib.nixvim.plugins.mkVimPlugin {
name = "emmet";
packPathName = "emmet-vim";
package = "emmet-vim";
globalPrefix = "user_emmet_";

maintainers = [ maintainers.GaetanLepage ];
maintainers = [ lib.maintainers.GaetanLepage ];

# TODO introduced 2024-03-01: remove 2024-05-01
deprecateExtraConfig = true;
Expand All @@ -24,7 +25,7 @@ mkVimPlugin {
];

settingsOptions = {
mode = helpers.defaultNullOpts.mkStr "a" ''
mode = defaultNullOpts.mkStr "a" ''
Choose modes, in which Emmet mappings will be created.
Default value: 'a' - all modes.
- 'n' - normal mode.
Expand All @@ -37,11 +38,11 @@ mkVimPlugin {
- create Emmet mappings for all modes: `a`
'';

leader_key = helpers.defaultNullOpts.mkStr "<C-y>" ''
leader_key = defaultNullOpts.mkStr "<C-y>" ''
Leading keys to run Emmet functions.
'';

settings = helpers.mkNullOrOption (with types; attrsOf anything) ''
settings = mkNullOrOption (with types; attrsOf anything) ''
Emmet settings.
Defaults: see https://github.com/mattn/emmet-vim/blob/master/autoload/emmet.vim
Expand Down

0 comments on commit e60ea67

Please sign in to comment.