nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 rustPlatform,
4 fetchFromGitHub,
5 nix-update-script,
6 makeWrapper,
7 rr,
8}:
9
10rustPlatform.buildRustPackage rec {
11 pname = "cargo-rr";
12 version = "0.3.0";
13
14 src = fetchFromGitHub {
15 owner = "danielzfranklin";
16 repo = "cargo-rr";
17 rev = "v${version}";
18 sha256 = "sha256-t8pRqeOdaRVG0titQhxezT2aDjljSs//MnRTTsJ73Yo=";
19 };
20
21 cargoHash = "sha256-s3KZFntAb/q4oreJLDQ2Pnz+Oj8Ik36vYR2InY0BIBw=";
22
23 passthru = {
24 updateScript = nix-update-script { };
25 };
26
27 nativeBuildInputs = [ makeWrapper ];
28
29 postInstall = ''
30 wrapProgram $out/bin/cargo-rr --prefix PATH : ${lib.makeBinPath [ rr ]}
31 '';
32
33 meta = with lib; {
34 description = "Cargo subcommand \"rr\": a light wrapper around rr, the time-travelling debugger";
35 mainProgram = "cargo-rr";
36 homepage = "https://github.com/danielzfranklin/cargo-rr";
37 license = with licenses; [ mit ];
38 maintainers = with maintainers; [
39 otavio
40 matthiasbeyer
41 ];
42 };
43}