Skip to content

Commit ba511a6

Browse files
committed
Add flake
1 parent 1b1022b commit ba511a6

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

flake.nix

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
{
2+
description = "NixCon 2025";
3+
4+
inputs = {
5+
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
6+
7+
};
8+
9+
outputs =
10+
{ self, ... }@inputs:
11+
with inputs;
12+
let
13+
# System types to support.
14+
supportedSystems = [
15+
"x86_64-linux"
16+
"x86_64-darwin"
17+
"aarch64-linux"
18+
"aarch64-darwin"
19+
];
20+
21+
# Helper function to generate an attrset '{ x86_64-linux = f "x86_64-linux"; ... }'.
22+
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
23+
24+
# Nixpkgs instantiated for supported system types.
25+
nixpkgsFor = forAllSystems (system: import nixpkgs { inherit system; });
26+
27+
in
28+
{
29+
nixosConfigurations = { };
30+
31+
devShells = forAllSystems (
32+
system:
33+
let
34+
pkgs = nixpkgsFor.${system};
35+
in
36+
{
37+
default = pkgs.mkShell {
38+
buildInputs = with pkgs; [
39+
just
40+
nodejs_20
41+
42+
];
43+
44+
shellHook = ''
45+
echo "To get startet run `just dev`"
46+
'';
47+
};
48+
}
49+
);
50+
51+
};
52+
}

0 commit comments

Comments
 (0)