Skip to content

Commit

Permalink
nvim-cmp: added confirmation config option
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexnortung committed Jul 18, 2022
1 parent b119553 commit fe6beaf
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion plugins/completion/nvim-cmp/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,19 @@ in
};
}));
};

confirmation = mkOption {
default = null;
type = types.nullOr (types.submodule ({...}: {
options = {
get_commit_characters = mkOption {
default = null;
type = types.nullOr types.str;
description = "Direct lua code as a string";
};
};
}));
};
};

config = let
Expand All @@ -154,7 +167,11 @@ in
autocomplete = if (isNull cfg.completion.autocomplete) then null else mkRaw cfg.completion.autocomplete;
completeopt = cfg.completion.completeopt;
};
# confirmation = cfg.confirmation;
confirmation = if (isNull cfg.confirmation) then null else {
get_commit_characters =
if (isString cfg.confirmation.get_commit_characters) then helpers.mkRaw cfg.confirmation.get_commit_characters
else cfg.confirmation.get_commit_characters;
};
# formatting = cfg.formatting;
# matching = cfg.matching;
# sorting = cfg.sorting;
Expand Down

0 comments on commit fe6beaf

Please sign in to comment.