diff options
Diffstat (limited to 'flake.nix')
-rw-r--r-- | flake.nix | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..10309ea --- /dev/null +++ b/flake.nix @@ -0,0 +1,43 @@ +{ + description = "Copied configurations"; + + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; + nixpkgs-master.url = "github:nixos/nixpkgs/master"; + + home-manager = { + url = "github:nix-community/home-manager"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + + nur.url = "github:nix-community/NUR"; + hardware.url = "github:nixos/nixos-hardware"; + impermanence.url = "github:nix-community/impermanence"; + }; + + outputs = { + self, + nixpkgs, + ... + } @ inputs: let + inherit (self) outputs; + systems = ["x86_64-linux"]; + forAllSystems = nixpkgs.lib.genAttrs systems; + in { + packages = forAllSystems (system: import ./pkgs {pkgs = nixpkgs.legacyPackages.${system};}); + formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra); + + overlays = import ./overlays {inherit inputs;}; + + nixosModules = import ./modules/nixos; + homeManagerModules = import ./modules/home-manager; + + # nixos-rebuild --flake .#nixbook + nixosConfigurations = { + nixosvm = nixpkgs.lib.nixosSystem { + specialArgs = {inherit inputs outputs;}; + modules = [./nixos/configuration.nix]; + }; + }; + }; +} |