Files
continuwuity/nix/rust.nix
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

33 lines
686 B
Nix
Raw Normal View History

2025-09-24 14:33:20 +02:00
{ inputs, ... }:
{
perSystem =
{
system,
2025-10-21 19:17:55 +02:00
lib,
2026-03-30 22:16:43 -04:00
pkgs,
2025-09-24 14:33:20 +02:00
...
}:
{
packages =
let
fnx = inputs.fenix.packages.${system};
2026-03-30 22:16:43 -04:00
stable-toolchain = fnx.fromToolchainFile {
2025-09-24 14:33:20 +02:00
file = inputs.self + "/rust-toolchain.toml";
# See also `rust-toolchain.toml`
2026-05-19 19:42:59 +00:00
sha256 = "sha256-gh/xTkxKHL4eiRXzWv8KP7vfjSk61Iq48x47BEDFgfk=";
2025-09-24 14:33:20 +02:00
};
in
{
2026-03-30 22:16:43 -04:00
inherit stable-toolchain;
2025-09-24 14:33:20 +02:00
dev-toolchain = fnx.combine [
2026-03-30 22:16:43 -04:00
stable-toolchain
2025-09-24 14:33:20 +02:00
# use the nightly rustfmt because we use nightly features
fnx.complete.rustfmt
];
};
};
}