From 446dd1ddbdc3e5fbd2556a2c7e87e7b195c56b18 Mon Sep 17 00:00:00 2001 From: Noa Aarts Date: Tue, 23 Jul 2024 21:36:07 +0200 Subject: [PATCH] feat: improve nvim config with nix --- common/nvim/init.lua | 4 ++++ common/nvim/nvim.nix | 44 +++++++++++++++++++++++++++----------------- 2 files changed, 31 insertions(+), 17 deletions(-) diff --git a/common/nvim/init.lua b/common/nvim/init.lua index 42a0bf2..5d06515 100644 --- a/common/nvim/init.lua +++ b/common/nvim/init.lua @@ -713,6 +713,10 @@ require("lazy").setup({ { "kenn7/vim-arsync", requires = { "prabirshrestha/async.vim" } }, + { + "nvim-tree/nvim-web-devicons", + }, + { -- Collection of various small independent plugins/modules "echasnovski/mini.nvim", config = function() diff --git a/common/nvim/nvim.nix b/common/nvim/nvim.nix index 6fdd8ac..8c70340 100644 --- a/common/nvim/nvim.nix +++ b/common/nvim/nvim.nix @@ -1,21 +1,31 @@ { pkgs, lib, ... }: - { - home.packages = with pkgs; [ - # needed for the nvim config, neovim itself is a system package already - ripgrep + programs.neovim = + { + enable = true; + extraPackages = with pkgs; [ + ripgrep + luarocks + gnumake + rustc + (python3.withPackages (python-pkgs: [ + python-pkgs.pip + ])) + wget + julia + gopls + nixpkgs-fmt + lua51Packages.lua + tree-sitter + php83Packages.composer + php83 + temurin-jre-bin + fd + ]; + defaultEditor = true; + viAlias = true; + vimAlias = true; - # TODO: find how I can make this build dependencies only - gnumake - rustc - python3 - ]; - programs.neovim = { - enable = true; - defaultEditor = true; - viAlias = true; - vimAlias = true; - - extraLuaConfig = lib.fileContents ./init.lua; - }; + extraLuaConfig = lib.fileContents ./init.lua; + }; }