1
0

flake.nix 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798
  1. {
  2. inputs = {
  3. nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05?shallow=true";
  4. nixpkgs-darwin.url = "github:nixos/nixpkgs/nixpkgs-25.05-darwin?shallow=true";
  5. nixpkgs-unstable.url = "github:nixos/nixpkgs/nixpkgs-unstable?shallow=true";
  6. nixos-facter-modules.url = "github:nix-community/nixos-facter-modules?shallow=true";
  7. # nixos-facter-modules.inputs.nixpkgs.follows = "nixpkgs";
  8. darwin.url = "github:lnl7/nix-darwin/nix-darwin-25.05?shallow=true";
  9. darwin.inputs.nixpkgs.follows = "nixpkgs-darwin";
  10. devenv.url = "github:cachix/devenv?shallow=true";
  11. devenv.inputs.nixpkgs.follows = "nixpkgs-unstable";
  12. home-manager.url = "github:nix-community/home-manager/master?shallow=true";
  13. home-manager.inputs.nixpkgs.follows = "nixpkgs";
  14. nixvim.url = "github:nix-community/nixvim/nixos-25.05?shallow=true";
  15. nixvim.inputs.nixpkgs.follows = "nixpkgs";
  16. impermanence.url = "github:nix-community/impermanence";
  17. # impermanence.inputs.nixpkgs.follows = "nixpkgs";
  18. sops-nix.url = "github:mic92/sops-nix?shallow=true";
  19. sops-nix.inputs.nixpkgs.follows = "nixpkgs";
  20. disko.url = "github:nix-community/disko?shallow=true";
  21. disko.inputs.nixpkgs.follows = "nixpkgs";
  22. };
  23. outputs = { self, ... } @ inputs: rec {
  24. lib = import ./lib {
  25. inherit inputs;
  26. inherit (self) outputs;
  27. };
  28. homeConfigurations = {
  29. "thomas@meili" = lib.mkHome {
  30. system = "aarch64-darwin";
  31. modules = [ ./home/meili.nix ];
  32. };
  33. "thomas@modgud" = lib.mkHome {
  34. system = "x86_64-linux";
  35. modules = [ ./home/modgud.nix ];
  36. };
  37. "thomas@fedora" = lib.mkHome {
  38. system = "aarch64-linux";
  39. modules = [ ./home/fedora.nix ];
  40. };
  41. "thomas@odin" = lib.mkHome {
  42. system = "x86_64-linux";
  43. modules = [ ./home/odin.nix ];
  44. };
  45. };
  46. nixosConfigurations = {
  47. # modgud = lib.mkSystem {
  48. # system = "x86_64-linux";
  49. # modules = [ ./hosts/modgud ];
  50. # };
  51. odin = lib.mkSystem {
  52. system = "x86_64-linux";
  53. modules = [ ./hosts/odin ];
  54. };
  55. };
  56. darwinConfigurations = {
  57. meili = lib.mkDarwin {
  58. system = "aarch64-darwin";
  59. modules = [ ./hosts/meili ];
  60. };
  61. };
  62. devShells = lib.mkDevenvShell {
  63. default = import ./devenv.nix;
  64. };
  65. modules = import ./modules;
  66. overlays = import ./overlays { inherit inputs; };
  67. packages = lib.eachSystem (system: {
  68. devenv-up = self.devShells.${system}.default.config.procfileScript;
  69. devenv-test = self.devShells.${system}.default.config.test;
  70. } // import ./packages { });
  71. templates = {
  72. devenv = {
  73. path = ./templates/devenv;
  74. description = "A template for a devenv environment";
  75. };
  76. };
  77. };
  78. }