-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathflake.nix
52 lines (47 loc) · 1.39 KB
/
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{
description = "Tmux status line configured in Rust";
inputs = {
flake-parts.url = "github:hercules-ci/flake-parts";
nixpkgs.url = "github:cachix/devenv-nixpkgs/rolling";
naersk.url = "github:nix-community/naersk";
systems.url = "github:nix-systems/default-linux";
};
outputs = inputs @ {
flake-parts,
systems,
...
}:
flake-parts.lib.mkFlake {inherit inputs;} {
systems = import systems;
perSystem = {
config,
self',
inputs',
pkgs,
system,
...
}: {
# Per-system attributes can be defined here. The self' and inputs'
# module parameters provide easy access to attributes of the same
# system.
packages = rec {
default = muxbar;
muxbar = inputs.naersk.lib.${system}.buildPackage {
src = ./.;
meta = {
mainProgram = "muxbar";
description = "Tmux status line configured in Rust";
homepage = "https://github.com/Dlurak/muxbar";
license = inputs.nixpkgs.lib.licenses.gpl3Only;
};
};
};
devShells.default = with pkgs; mkShell {
buildInputs = [ cargo rustc rustfmt pre-commit rustPackages.clippy ];
RUST_SRC_PATH = rustPlatform.rustLibSrc;
};
formatter = pkgs.alejandra;
};
flake = {};
};
}