-
Notifications
You must be signed in to change notification settings - Fork 105
Expand file tree
/
Copy pathflake.nix
More file actions
79 lines (75 loc) · 2.43 KB
/
flake.nix
File metadata and controls
79 lines (75 loc) · 2.43 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
{
description = "orb-software flake";
inputs = {
# Different versions of nixpkgs
nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05";
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
nixpkgs-23_11.url = "github:NixOS/nixpkgs/nixos-23.11";
# Provides eachDefaultSystem and other utility functions
flake-utils.url = "github:numtide/flake-utils";
# Replacement for rustup
fenix = {
url = "github:nix-community/fenix";
inputs.nixpkgs.follows = "nixpkgs";
};
# Manages dotfiles and home environment
home-manager = {
url = "github:nix-community/home-manager/release-25.05";
inputs.nixpkgs.follows = "nixpkgs";
};
# Supports generating liveusbs
disko = {
url = "github:nix-community/disko/v1.12.0";
inputs.nixpkgs.follows = "nixpkgs";
};
pyproject-nix = {
url = "github:pyproject-nix/pyproject.nix";
inputs.nixpkgs.follows = "nixpkgs";
};
uv2nix = {
url = "github:pyproject-nix/uv2nix";
inputs.nixpkgs.follows = "nixpkgs";
inputs.pyproject-nix.follows = "pyproject-nix";
};
pyproject-build-systems = {
url = "github:pyproject-nix/build-system-pkgs";
inputs.pyproject-nix.follows = "pyproject-nix";
inputs.uv2nix.follows = "uv2nix";
inputs.nixpkgs.follows = "nixpkgs";
};
# Replaces the need to have a git submodule.
seekSdk = {
url = "github:worldcoin/seek-thermal-sdk";
flake = false;
};
};
outputs =
inputs:
let
# Used for conveniently accessing nixpkgs on different platforms.
# We instantiate this once here, and then use it in various other places.
p = (import ./nix/packages/nixpkgs.nix { inherit inputs; });
# Creates all of the nixos machines for the flake.
machines = (import nix/machines/flake-outputs.nix { inherit p inputs; });
# Creates a `nix develop` shell for every host platform.
devShells = (
import nix/shells/flake-outputs.nix {
inherit inputs;
instantiatedPkgs = p;
}
);
containers = (
import nix/containers/flake-outputs.nix {
inherit inputs;
instantiatedPkgs = p;
}
);
lib = inputs.nixpkgs.lib;
in
# This is like repeatedly doing a deep version of the `//` operator to combine into one big attrset.
lib.foldl' lib.recursiveUpdate { } [
machines
devShells
containers
];
}