diff options
| author | seth <[email protected]> | 2023-11-13 20:45:35 -0500 |
|---|---|---|
| committer | seth <[email protected]> | 2023-11-14 02:55:54 +0000 |
| commit | 3e5263a327a3261d3d9957d723e9dc0e1d96e094 (patch) | |
| tree | 662921851c149f1dd61252584081dc754059732d /ci.nix | |
| parent | e1387ae4821a95efabb356581f2234ef4aab42cb (diff) | |
ci!: gha -> garnix
compiling arm stuff with qemu is way too slow lol
Diffstat (limited to 'ci.nix')
| -rw-r--r-- | ci.nix | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -0,0 +1,28 @@ +{self, ...}: { + perSystem = { + lib, + pkgs, + system, + config, + ... + }: let + # get applicable system configurations + configurations = lib.getAttrs ["darwinConfigurations" "homeConfigurations" "nixosConfigurations"] self; + + systems = lib.pipe (builtins.attrValues configurations) [ + (builtins.foldl' (acc: attr: acc // attr) {}) + (lib.filterAttrs (_: v: v.pkgs.system == system)) + (lib.mapAttrsToList (_: v: v.config.system.build.toplevel or v.activationPackage)) + ]; + in { + checks = { + ciGate = pkgs.runCommand "ci-gate" { + nativeBuildInputs = lib.concatLists [ + systems + # and other checks + (builtins.attrValues (builtins.removeAttrs config.checks ["ciGate"])) + ]; + } "touch $out"; + }; + }; +} |
