forked from numtide/flake-utils
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
28 lines (26 loc) · 779 Bytes
/
flake.nix
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
{
description = "Flake utils demo";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem (system:
let pkgs = nixpkgs.legacyPackages.${system}; in
{
packages = {
default = pkgs.hello;
# `nix run .#find` will work because findutils.meta.mainProgram is set to "find".
find = pkgs.findutils;
};
# Use apps to expose packages that have multiple binaries.
apps = {
xargs = flake-utils.lib.mkApp {
drv = pkgs.findutils;
name = "xargs";
};
ls = flake-utils.lib.mkApp {
drv = pkgs.coreutils;
name = "ls";
};
};
}
);
}