-
Notifications
You must be signed in to change notification settings - Fork 930
Expand file tree
/
Copy pathflake.nix
More file actions
59 lines (52 loc) · 1.51 KB
/
Copy pathflake.nix
File metadata and controls
59 lines (52 loc) · 1.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
{
description = "Aspire CLI";
inputs = {
# Default package set used when evaluating this flake directly. Consumers can
# make this input follow their own pinned nixpkgs input.
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
};
outputs =
{ self, nixpkgs }:
let
manifest = builtins.fromJSON (builtins.readFile ./eng/nix/versions.json);
supportedSystems = builtins.attrNames manifest.systems;
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
packageFor =
system:
let
pkgs = nixpkgs.legacyPackages.${system};
in
pkgs.callPackage ./eng/nix/package.nix {
inherit manifest;
};
in
{
packages = forAllSystems (
system:
let
aspireCli = packageFor system;
in
{
aspire-cli = aspireCli;
default = aspireCli;
}
);
apps = forAllSystems (system: {
aspire-cli = {
type = "app";
program = "${self.packages.${system}.aspire-cli}/bin/aspire";
meta.description = "Run the Aspire CLI";
};
default = self.apps.${system}.aspire-cli;
});
overlays.default = final: _prev: {
aspire-cli = final.callPackage ./eng/nix/package.nix {
inherit manifest;
};
};
checks = forAllSystems (system: {
aspire-cli = self.packages.${system}.aspire-cli;
});
formatter = forAllSystems (system: nixpkgs.legacyPackages.${system}.nixfmt);
};
}