neovim-flake/modules/assistant/copilot.nix
2023-02-06 04:14:01 +03:00

24 lines
458 B
Nix

{
pkgs,
config,
lib,
...
}:
with lib;
with builtins; let
cfg = config.vim.assistant.copilot;
in {
options.vim.assistant.copilot = {
enable = mkEnableOption "Enable GitHub Copilot";
};
config = mkIf cfg.enable {
vim.startPlugins = ["copilot-lua"];
vim.luaConfigRC.copilot = nvim.dag.entryAnywhere ''
require("copilot").setup({
-- available options: https://github.com/zbirenbaum/copilot.lua
})
'';
};
}