mirror of
https://github.com/NotAShelf/nvf.git
synced 2024-11-02 11:31:15 +00:00
25 lines
465 B
Nix
25 lines
465 B
Nix
|
{
|
||
|
pkgs,
|
||
|
config,
|
||
|
lib,
|
||
|
...
|
||
|
}:
|
||
|
with lib;
|
||
|
with builtins; let
|
||
|
cfg = config.vim.assistant.copilot;
|
||
|
in {
|
||
|
config = mkIf cfg.enable {
|
||
|
vim.startPlugins = [
|
||
|
"copilot-lua"
|
||
|
pkgs.nodejs-slim-16_x
|
||
|
];
|
||
|
|
||
|
vim.luaConfigRC.copilot = nvim.dag.entryAnywhere ''
|
||
|
require("copilot").setup({
|
||
|
-- available options: https://github.com/zbirenbaum/copilot.lua
|
||
|
copilot_node_command = "${cfg.copilot_node_command}",
|
||
|
})
|
||
|
'';
|
||
|
};
|
||
|
}
|