mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
copilot: add package option (#84)
This commit is contained in:
parent
de6519f713
commit
470fd9c07e
1 changed files with 6 additions and 1 deletions
|
@ -7,6 +7,11 @@ in
|
|||
options = {
|
||||
plugins.copilot = {
|
||||
enable = mkEnableOption "Enable copilot";
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
description = "The copilot plugin package to use";
|
||||
default = pkgs.vimPlugins.copilot-vim;
|
||||
};
|
||||
filetypes = mkOption {
|
||||
type = types.attrsOf types.bool;
|
||||
description = "A dictionary mapping file types to their enabled status";
|
||||
|
@ -27,7 +32,7 @@ in
|
|||
|
||||
config =
|
||||
mkIf cfg.enable {
|
||||
extraPlugins = [ pkgs.vimPlugins.copilot-vim ];
|
||||
extraPlugins = [ cfg.package ];
|
||||
globals = {
|
||||
copilot_node_command = "${pkgs.nodejs-16_x}/bin/node";
|
||||
copilot_filetypes = cfg.filetypes;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue