mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-15 14:26:33 +01:00
38 lines
820 B
Nix
38 lines
820 B
Nix
{
|
|
lib,
|
|
rustPlatform,
|
|
fetchFromGitHub,
|
|
makeWrapper,
|
|
calibre,
|
|
gitUpdater,
|
|
}:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "unbook";
|
|
version = "0.9.1";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "ludios";
|
|
repo = "unbook";
|
|
rev = version;
|
|
hash = "sha256-whWWh/jQ4RkGA3T1VCmt6zhpQQCzh2jASYg69IlfEeo=";
|
|
};
|
|
|
|
cargoHash = "sha256-whmp4ST89TZuxQe9fnkW98A9t3rwpTdQCej49ZsDanE=";
|
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
postInstall = ''
|
|
wrapProgram $out/bin/unbook --prefix PATH : ${lib.makeBinPath [ calibre ]}
|
|
'';
|
|
|
|
passthru.updateScript = gitUpdater { };
|
|
|
|
meta = with lib; {
|
|
description = "Ebook to self-contained-HTML converter";
|
|
homepage = "https://unbook.ludios.org";
|
|
license = licenses.cc0;
|
|
maintainers = with maintainers; [ jmbaur ];
|
|
mainProgram = "unbook";
|
|
};
|
|
}
|