This repository has been archived on 2024-05-17. You can view files and clone it, but cannot push or open issues or pull requests.
neovim/flake.nix

39 lines
833 B
Nix
Raw Normal View History

2022-09-15 01:22:06 +03:00
{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
utils.url = "github:numtide/flake-utils";
2022-09-16 09:59:56 +03:00
# nix lsp
nil.url = "github:oxalica/nil";
2022-09-15 01:22:06 +03:00
};
2022-09-16 09:59:56 +03:00
outputs = input @ { self, nixpkgs, utils, ... }:
2022-09-15 01:22:06 +03:00
utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
2022-09-15 01:29:25 +03:00
neovim = pkgs.callPackage ./. { };
2022-09-16 09:59:56 +03:00
nil = input.nil.packages.${system}.nil;
2022-09-15 01:22:06 +03:00
in
{
2022-09-17 17:52:12 +03:00
apps.default = {
type = "app";
program = "${neovim}/bin/nvim";
};
packages.default = neovim;
2022-09-15 01:22:06 +03:00
devShells.default = pkgs.mkShell {
2022-09-16 23:42:53 +03:00
packages = [
neovim
nil # nix lsp
pkgs.stylua # lua formatter
];
2022-09-15 01:22:06 +03:00
};
2022-09-17 17:52:12 +03:00
overlays = f: p: {
myneovim = neovim;
};
2022-09-15 01:22:06 +03:00
});
}