feat(nvim): Move neovim config to a sub-flake

This commit is contained in:
uttarayan21
2024-03-29 19:00:05 +05:30
parent 85c4f13f56
commit eb13211abe
12 changed files with 1785 additions and 658 deletions

47
neovim/flake.nix Normal file
View File

@@ -0,0 +1,47 @@
{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
systems.url = "github:nix-systems/default";
nixvim = {
url = "github:nix-community/nixvim";
inputs.nixpkgs.follows = "nixpkgs";
};
nnn = {
url = "github:nix-community/neovim-nightly-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
nvim-devdocs.url = "github:luckasRanarison/nvim-devdocs";
nvim-devdocs.flake = false;
};
outputs = {
self,
nixpkgs,
systems,
nixvim,
nnn,
...
} @ inputs: let
forEachSystem = nixpkgs.lib.genAttrs (import systems);
nvim = forEachSystem (system:
import ./nvim.nix {
pkgs = import nixpkgs {
inherit system;
overlays = import ./overlays.nix {
inherit inputs;
};
};
});
in rec {
packages = forEachSystem (system: rec {
neovim = nvim.${system}.neovim;
default = neovim;
});
overlays = {
default = prev: final: {
sneovim = packages.${final.system}.neovim;
};
};
};
}