force use of nixpkgs' tabnine package in nvim/emacs
Alan Pearce alan@alanpearce.eu
Mon, 10 Apr 2023 11:44:39 +0200
2 files changed, 7 insertions(+), 0 deletions(-)
M user/settings/emacs.nix → user/settings/emacs.nix
@@ -161,6 +161,10 @@ ]); extraConfig = '' (with-eval-after-load 'editorconfig (setq editorconfig-exec-path "${pkgs.editorconfig-core-c}/bin/editorconfig")) + (with-eval-after-load 'company-tabnine + (advice-add 'company-tabnine--executable-path :around + (lambda (original-function &rest args) + "${pkgs.tabnine}/bin/TabNine"))) '' + lib.optionalString stdenv.isDarwin '' (with-eval-after-load 'files (setq insert-directory-program "${pkgs.coreutils-prefixed}/bin/gls"))
M user/settings/neovim.nix → user/settings/neovim.nix
@@ -24,6 +24,9 @@ "json.enable" = true; "suggest.enablePreview" = true; "coc.preferences.formatOnSaveFiletypes" = [ "nix" ]; "nil.formatting.command" = "nixpkgs-fmt"; + tabnine = { + binary_path = "${pkgs.tabnine}/bin/TabNine"; + }; semantictokens = { filetypes = [ "nix" ]; };