lol
at 22.05-pre 28 lines 685 B view raw
1{ lib, fetchFromGitHub, rustPlatform }: 2 3rustPlatform.buildRustPackage rec { 4 pname = "fend"; 5 version = "0.1.26"; 6 7 src = fetchFromGitHub { 8 owner = "printfn"; 9 repo = pname; 10 rev = "v${version}"; 11 sha256 = "sha256-U5LYjoq11qZYus/McDbtVljj2RSP9MCXXDvOWgbXerk="; 12 }; 13 14 cargoSha256 = "sha256-E7by7FJfmOBqDoZLA9s/bj/EHaZ4IsHYTHWcvIuaMNg="; 15 16 doInstallCheck = true; 17 18 installCheckPhase = '' 19 [[ "$($out/bin/fend "1 km to m")" = "1000 m" ]] 20 ''; 21 22 meta = with lib; { 23 description = "Arbitrary-precision unit-aware calculator"; 24 homepage = "https://github.com/printfn/fend"; 25 license = licenses.mit; 26 maintainers = with maintainers; [ djanatyn ]; 27 }; 28}