Skip to content

Commit

Permalink
plugins/copilot-vim: remove deprecation warning
Browse files Browse the repository at this point in the history
  • Loading branch information
GaetanLepage committed Feb 9, 2024
1 parent eec8d6b commit b30e8a1
Showing 1 changed file with 31 additions and 37 deletions.
68 changes: 31 additions & 37 deletions plugins/completion/copilot-vim.nix
Original file line number Diff line number Diff line change
Expand Up @@ -3,46 +3,40 @@
pkgs,
...
} @ args:
with lib;
(
with (import ../helpers.nix {inherit lib;}).vim-plugin;
mkVimPlugin args {
name = "copilot-vim";
description = "copilot.vim";
package = pkgs.vimPlugins.copilot-vim;
globalPrefix = "copilot_";
with lib; (
with (import ../helpers.nix {inherit lib;}).vim-plugin;
mkVimPlugin args {
name = "copilot-vim";
description = "copilot.vim";
package = pkgs.vimPlugins.copilot-vim;
globalPrefix = "copilot_";

options = {
nodeCommand = mkDefaultOpt {
global = "node_command";
type = types.str;
default = "${pkgs.nodejs-18_x}/bin/node";
description = "Tell Copilot what `node` binary to use.";
};
options = {
nodeCommand = mkDefaultOpt {
global = "node_command";
type = types.str;
default = "${pkgs.nodejs-18_x}/bin/node";
description = "Tell Copilot what `node` binary to use.";
};

filetypes = mkDefaultOpt {
type = with types; attrsOf bool;
description = ''
A dictionary mapping file types to their enabled status
filetypes = mkDefaultOpt {
type = with types; attrsOf bool;
description = ''
A dictionary mapping file types to their enabled status
Default: `{}`
'';
example = {
"*" = false;
python = true;
};
Default: `{}`
'';
example = {
"*" = false;
python = true;
};
};

proxy = mkDefaultOpt {
type = types.str;
description = "Tell Copilot what proxy server to use.";
example = "localhost:3128";
};
proxy = mkDefaultOpt {
type = types.str;
description = "Tell Copilot what proxy server to use.";
example = "localhost:3128";
};
}
)
// {
imports = [
(lib.mkRenamedOptionModule ["plugins" "copilot"] ["plugins" "copilot-vim"])
];
}
};
}
)

0 comments on commit b30e8a1

Please sign in to comment.