Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- description = "My NixOS configuration";
- inputs = {
- nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
- hardware.url = "github:nixos/nixos-hardware";
- home-manager = {
- url = "github:nix-community/home-manager";
- inputs.nixpkgs.follows = "nixpkgs";
- };
- };
- outputs = { self, nixpkgs, home-manager, ... }@inputs:
- let
- inherit (self) outputs;
- lib = nixpkgs.lib // home-manager.lib;
- systems = [ "x86_64-linux" "aarch64-linux" ];
- forEachSystem = f: lib.genAttrs systems (system: f pkgsFor.${system});
- pkgsFor = lib.genAttrs systems (system: import nixpkgs {
- inherit system;
- config.allowUnfree = true;
- });
- in
- {
- inherit lib;
- nixosModules = import ./modules/nixos;
- homeManagerModules = import ./modules/home-manager;
- templates = import ./templates;
- overlays = import ./overlays { inherit inputs outputs; };
- hydraJobs = import ./hydra.nix { inherit inputs outputs; };
- packages = forEachSystem (pkgs: import ./pkgs { inherit pkgs; });
- devShells = forEachSystem (pkgs: import ./shell.nix { inherit pkgs; });
- formatter = forEachSystem (pkgs: pkgs.nixpkgs-fmt);
- nixosConfigurations = {
- laptop = lib.nixosSystem {
- modules = [ ./hosts/laptop ];
- specialArgs = { inherit inputs outputs; };
- };
- pi = lib.nixosSystem {
- modules = [ ./hosts/pi ];
- specialArgs = { inherit inputs outputs; };
- };
- };
- };
- }
Advertisement
Add Comment
Please, Sign In to add comment