refactor: use flake parts

This commit is contained in:
Oliver Davies 2023-05-04 00:04:02 +01:00
parent 967e7e7bf8
commit 32c6ee2171

View file

@ -4,14 +4,21 @@
inputs.neovim-nightly.url = "github:nix-community/neovim-nightly-overlay";
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
outputs = inputs@{ home-manager, neovim-nightly, flake-parts, nixpkgs, self, ... }:
outputs =
inputs@{ flake-parts, home-manager, neovim-nightly, nixpkgs, self, ... }:
let
overlays = [ neovim-nightly.overlay ];
system = "x86_64-linux";
in
{
formatter.${system} = nixpkgs.legacyPackages.${system}.nixpkgs-fmt;
flake-parts.lib.mkFlake { inherit inputs; } {
systems = [ "x86_64-linux" ];
perSystem = { pkgs, self', nixpkgs, ... }: {
packages.default = self'.packages.activate;
formatter = pkgs.nixpkgs-fmt;
};
flake = {
nixosConfigurations = {
apollo = nixpkgs.lib.nixosSystem {
modules = [
@ -51,4 +58,5 @@
};
};
};
};
}