nixpkgs/pkgs/tools/backup/diskrsync/default.nix

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

32 lines
794 B
Nix
Raw Permalink Normal View History

{ buildGoModule, fetchFromGitHub, lib, openssh, makeWrapper }:
2017-12-31 09:52:30 +01:00
buildGoModule rec {
2017-12-31 09:52:30 +01:00
pname = "diskrsync";
version = "1.3.0";
2017-12-31 09:52:30 +01:00
src = fetchFromGitHub {
owner = "dop251";
repo = pname;
rev = "v${version}";
sha256 = "sha256-hM70WD+M3jwze0IG84WTFf1caOUk2s9DQ7pR+KNIt1M=";
2017-12-31 09:52:30 +01:00
};
vendorHash = "sha256-lJaM/sC5/qmmo7Zu7nGR6ZdXa1qw4SuVxawQ+d/m+Aw=";
ldflags = [ "-s" "-w" ];
2017-12-31 09:52:30 +01:00
nativeBuildInputs = [ makeWrapper ];
preFixup = ''
wrapProgram "$out/bin/diskrsync" --argv0 diskrsync --prefix PATH : ${openssh}/bin
'';
meta = with lib; {
2017-12-31 09:52:30 +01:00
description = "Rsync for block devices and disk images";
mainProgram = "diskrsync";
homepage = "https://github.com/dop251/diskrsync";
2017-12-31 09:52:30 +01:00
license = licenses.mit;
maintainers = with maintainers; [ jluttine ];
};
}