oizys/modules/languages/zig.nix

22 lines
332 B
Nix
Raw Normal View History

2024-04-05 12:18:44 -05:00
{
config,
lib,
2024-07-25 09:57:26 -05:00
pkgsFrom,
pkgFrom,
2024-04-05 12:18:44 -05:00
...
2024-05-06 14:32:00 -05:00
}:
let
2024-04-05 12:18:44 -05:00
inherit (lib) mkIfIn;
cfg = config.oizys.languages;
2024-07-25 09:57:26 -05:00
zig = (pkgsFrom "zig2nix").zig.master.bin;
zls = (pkgFrom "zls").overrideAttrs { nativeBuildInputs = [ zig ]; };
2024-05-06 14:32:00 -05:00
in
{
2024-04-05 12:18:44 -05:00
config = mkIfIn "zig" cfg {
2024-05-06 14:32:00 -05:00
environment.systemPackages = [
zig
zls
];
2024-04-05 12:18:44 -05:00
};
}