{ description = "My various NixOs configurations"; inputs = { nixpkgs.url = "github:NixOs/nixpkgs/nixos-24.05"; nixpkgs-unstable.url = "github:NixOs/nixpkgs/nixos-unstable"; flake-utils.url = "github:numtide/flake-utils"; home-manager = { url = "github:nix-community/home-manager/release-24.05"; inputs.nixpkgs.follows = "nixpkgs"; }; agda = { url = "github:agda/agda/v2.6.4.1"; inputs.nixpkgs.follows = "nixpkgs"; }; cornelis = { url = "github:isovector/cornelis/"; inputs.nixpkgs.follows = "nixpkgs"; }; ssbm-nix = { url = "github:lytedev/ssbm-nix"; inputs.nixpkgs.follows = "nixpkgs-unstable"; }; plasma-manager = { url = "github:nix-community/plasma-manager"; inputs.nixpkgs.follows = "nixpkgs"; inputs.home-manager.follows = "home-manager"; }; }; outputs = { self, nixpkgs, nixpkgs-unstable, home-manager, agda, cornelis, ssbm-nix, plasma-manager, flake-utils }: let nix-config-module = { nix.registry.nixpkgs.flake = nixpkgs; nix.registry.unstable.flake = nixpkgs-unstable; system.configurationRevision = nixpkgs.lib.mkIf (self ? rev) self.rev; }; rachel-home-module = system: { home-manager = { sharedModules = [ plasma-manager.homeManagerModules.plasma-manager ]; useGlobalPkgs = true; useUserPackages = true; users.rachel = import ./home-manager/all.nix { pkgs = import nixpkgs { system = system; config.allowUnfree = true; }; unstable = import nixpkgs-unstable { system = system; config.allowUnfree = true; }; extra = { agda = agda.packages.${system}.Agda; cornelis = cornelis.packages.${system}.cornelis; cornelis-vim = cornelis.packages.${system}.cornelis-vim; slippi-netplay = ssbm-nix.packages.${system}.slippi-netplay; sax2nf = self.packages.${system}.sax2nf; bqn-vim = self.packages.${system}.bqn-vim; bqn-nvim = self.packages.${system}.bqn-nvim; shell-menu = self.packages.${system}.shell-menu; }; }; }; }; base-modules = [ nix-config-module ssbm-nix.nixosModule home-manager.nixosModules.home-manager ]; in { nixosConfigurations.lambda = nixpkgs.lib.nixosSystem rec { system = "x86_64-linux"; modules = base-modules ++ [ ./nixos/lambda/configuration.nix ./nixos/shared/user-system.nix ./nixos/shared/graphical.nix (rachel-home-module system) ]; }; nixosConfigurations.computational = nixpkgs.lib.nixosSystem rec { system = "x86_64-linux"; modules = base-modules ++ [ ./nixos/computational/configuration.nix ./nixos/shared/user-system.nix ./nixos/shared/graphical.nix (rachel-home-module system) ]; }; keyboardLayouts.fox = ./resources/fox.xkb; keyboardLayouts.sus = ./resources/fox.xkb; } // flake-utils.lib.eachDefaultSystem (system: let pkgs = nixpkgs.legacyPackages.${system}; in { packages = { bqn-vim = import ./pkgs/bqn-vim.nix { inherit pkgs; }; bqn-nvim = import ./pkgs/bqn-nvim.nix { inherit pkgs; }; sax2nf = import ./pkgs/sax2nf.nix { inherit pkgs; }; shell-menu = import ./pkgs/shell-menu.nix { inherit pkgs; }; }; }); }