]> git.scottworley.com Git - git-cache/blob - flake.nix
49594a700f0186be3be5525cf4610dc07ed00f5b
[git-cache] / flake.nix
1 {
2 inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-20.03"; };
3 outputs = { self, nixpkgs, }:
4 let
5
6 inherit (builtins) attrNames;
7 inherit (nixpkgs.lib) genAttrs;
8
9 for-supported-systems = genAttrs (attrNames
10 ((import (nixpkgs + "/pkgs/top-level/release.nix")
11 { }).stdenvBootstrapTools));
12
13 packages = for-supported-systems (system: {
14 git-cache = import ./. { pkgs = nixpkgs.legacyPackages."${system}"; };
15 });
16
17 in {
18 inherit packages;
19
20 defaultApp = for-supported-systems (system: {
21 type = "app";
22 program = "${packages."${system}".git-cache}/bin/git-cache";
23 });
24 };
25 }