From f3ad77abf0d7e7cded863c2cad324ffea0082c19 Mon Sep 17 00:00:00 2001 From: Lillian-Violet Date: Thu, 18 Jan 2024 11:59:01 +0100 Subject: [PATCH] Let's refactor based on the template, maybe this works --- flake.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/flake.nix b/flake.nix index 5374ed2..3b565c4 100644 --- a/flake.nix +++ b/flake.nix @@ -50,7 +50,25 @@ ... } @ inputs: let inherit (self) outputs; + # Supported systems for your flake packages, shell, etc. + systems = [ + "armv7l-linux" + "x86_64-linux" + ]; + # This is a function that generates an attribute by calling a function you + # pass to it, with each system as an argument + forAllSystems = nixpkgs.lib.genAttrs systems; in { + # Your custom packages + # Accessible through 'nix build', 'nix shell', etc + packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system}); + # Formatter for your nix files, available through 'nix fmt' + # Other options beside 'alejandra' include 'nixpkgs-fmt' + formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.alejandra); + + # Your custom packages and modifications, exported as overlays + overlays = import ./overlays {inherit inputs;}; + # NixOS configuration entrypoint # Available through 'nixos-rebuild --flake .#your-hostname' nixosConfigurations = {