From 107b572e1ccf0d189e34931f2c4cfa40ad085722 Mon Sep 17 00:00:00 2001 From: NotAShelf Date: Wed, 15 Feb 2023 11:47:08 +0300 Subject: [PATCH] feat: bundle nodejs_16 slim with copilot & move copilot to maximal --- extra.nix | 4 ++-- modules/assistant/copilot.nix | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/extra.nix b/extra.nix index 620efe1..1cdeda2 100644 --- a/extra.nix +++ b/extra.nix @@ -148,8 +148,8 @@ inputs: let }; vim.assistant = { - copilot.enable = false; - tabnine.enable = false; # FIXME: this is not working because the plugin depends on an internal script to be ran by the package manager + copilot.enable = isMaximal; + #tabnine.enable = false; # FIXME: this is not working because the plugin depends on an internal script to be ran by the package manager }; vim.session = { diff --git a/modules/assistant/copilot.nix b/modules/assistant/copilot.nix index c6bb1ec..b15d262 100644 --- a/modules/assistant/copilot.nix +++ b/modules/assistant/copilot.nix @@ -13,11 +13,15 @@ in { }; config = mkIf cfg.enable { - vim.startPlugins = ["copilot-lua"]; + 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 = "${lib.getExe pkgs.nodejs-slim-16_x}", }) ''; };