From 5df3516aa89fcbe176b0443ce81ec34279a6f8ae Mon Sep 17 00:00:00 2001 From: Sean Buckley Date: Sun, 15 Oct 2023 17:13:47 -0400 Subject: [PATCH] switch lvim to new PR --- modules/vim/default.nix | 15 --------------- pkgs/lunarvim.nix | 30 ++++++++++-------------------- 2 files changed, 10 insertions(+), 35 deletions(-) diff --git a/modules/vim/default.nix b/modules/vim/default.nix index d17e15e..153ec41 100644 --- a/modules/vim/default.nix +++ b/modules/vim/default.nix @@ -2,13 +2,6 @@ { environment.variables.EDITOR = "vim"; - environment.etc."lvim.lua".source = ./init.lua; - - environment.etc."my-settings.sh".text = '' - mkdir -p ~/.config/lvim - echo 'vim.cmd("luafile /etc/lvim.lua")' >~/.config/lvim/config.lua - ''; - environment.systemPackages = with pkgs; [ lunarvim nodePackages.prettier @@ -16,13 +9,5 @@ (writeShellScriptBin "black" '' exec ${pkgs.python3.pkgs.black}/bin/black "$@" '') - - (writeShellScriptBin "vi" '' - exec lvim "$@" - '') - - (writeShellScriptBin "vim" '' - exec lvim "$@" - '') ]; } diff --git a/pkgs/lunarvim.nix b/pkgs/lunarvim.nix index a68ba09..35a689c 100644 --- a/pkgs/lunarvim.nix +++ b/pkgs/lunarvim.nix @@ -1,28 +1,18 @@ # -# https://github.com/NixOS/nixpkgs/pull/257063 +# https://github.com/NixOS/nixpkgs/pull/261103 # { pkgs }: ( - ( - pkgs.callPackage - (pkgs.fetchurl { - url = "https://raw.githubusercontent.com/NixOS/nixpkgs/266e0f99a483d8e699f32b050c55981fd950de70/pkgs/by-name/lu/lunarvim/package.nix"; - sha256 = "fa44f06a517c686d181f35ee255d4e0c00c6f52473cf1a3b9586c4e511efb7d7"; - }) - { } - - ).overrideAttrs (_: { - patches = [ - ( - pkgs.fetchurl { - url = "https://github.com/LunarVim/LunarVim/commit/d187cbd03fbc8bd1b59250869e0e325518bf8798.patch"; - sha256 = "00677d3d5a4882d7ee5709e0494a5d8f7c58cea8bdcf467ce59222f9cc493366"; - } - ) - ]; - }) + pkgs.callPackage + (pkgs.fetchurl { + url = "https://raw.githubusercontent.com/NixOS/nixpkgs/99dadc5f534b7ba85582c8ee492599585069d20e/pkgs/by-name/lu/lunarvim/package.nix"; + sha256 = "211d9cf8d5d352d220785ba90c7800d588c34e6e1c4a3dcbf02013d1fa49977c"; + }) + { } ).override (_: { - python3.withPackages = _: pkgs.emptyDirectory; + viAlias = true; + vimAlias = true; + globalConfig = builtins.readFile ../modules/vim/init.lua; })