3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/mobile/adb-sync/default.nix

44 lines
1.2 KiB
Nix
Raw Normal View History

{ stdenv, fetchFromGitHub, python3, platform-tools, makeWrapper
, socat, go-mtpfs, adbfs-rootless
}:
2016-08-07 12:25:41 +01:00
2019-08-13 22:52:01 +01:00
stdenv.mkDerivation {
pname = "adb-sync-unstable";
version = "2019-01-01";
2016-08-07 12:25:41 +01:00
src = fetchFromGitHub {
owner = "google";
repo = "adb-sync";
rev = "fb7c549753de7a5579ed3400dd9f8ac71f7bf1b1";
sha256 = "1kfpdqs8lmnh144jcm1qmfnmigzrbrz5lvwvqqb7021b2jlf69cl";
2016-08-07 12:25:41 +01:00
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ python3 ];
2016-08-07 12:25:41 +01:00
dontBuild = true;
installPhase = let
dependencies = stdenv.lib.makeBinPath [ platform-tools socat go-mtpfs adbfs-rootless ];
in ''
runHook preInstall
2016-08-07 12:25:41 +01:00
mkdir -p $out/bin
cp adb-{sync,channel} $out/bin
wrapProgram $out/bin/adb-sync --suffix PATH : "${dependencies}"
wrapProgram $out/bin/adb-channel --suffix PATH : "${dependencies}"
runHook postInstall
2016-08-07 12:25:41 +01:00
'';
meta = with stdenv.lib; {
description = "A tool to synchronise files between a PC and an Android devices using ADB (Android Debug Bridge)";
homepage = "https://github.com/google/adb-sync";
2016-08-07 12:25:41 +01:00
license = licenses.asl20;
platforms = platforms.unix;
hydraPlatforms = [];
maintainers = with maintainers; [ scolobb ma27 ];
2016-08-07 12:25:41 +01:00
};
}