add smfh as a package for stable users

This commit is contained in:
atagen 2025-08-08 11:11:57 +10:00
parent 891886234d
commit 60ff6e4dc0
2 changed files with 21 additions and 0 deletions

View file

@ -193,6 +193,7 @@ in
after = [ "arbys-prep.service" ];
script =
let
linker = lib.getExe (pkgs.smfh or (pkgs.rustPlatform.buildRustPackage ./smfh.nix { }));
in
''
new_manifest=${manifest}

20
smfh.nix Normal file
View file

@ -0,0 +1,20 @@
{
rustPlatform,
fetchFromGitHub,
}:
let
src = fetchFromGitHub {
owner = "feel-co";
repo = "smfh";
rev = "39f5c06153f63100376bc607b1465850b6df77fd";
hash = "sha256-/9Ww10kYopxfCNNnNDwENTubs7Wzqlw+O6PJAHNOYQw=";
};
cargo = (builtins.fromTOML (builtins.readFile "${src}/Cargo.toml"));
in
rustPlatform.buildRustPackage {
inherit src;
inherit (cargo.package) version;
pname = cargo.package.name;
cargoLock.lockFile = "${src}/Cargo.lock";
meta.mainProgram = "smfh";
}