Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / adb-enhanced / default.nix
blob739d34014357314ac992285676957b991a0ff3e4
1 { lib
2 , buildPythonPackage
3 , docopt
4 , fetchFromGitHub
5 , jdk11
6 , psutil
7 , pythonOlder
8 }:
10 buildPythonPackage rec {
11   pname = "adb-enhanced";
12   version = "2.5.22";
13   format = "setuptools";
15   disabled = pythonOlder "3.7";
17   src = fetchFromGitHub {
18     owner = "ashishb";
19     repo = pname;
20     rev = "refs/tags/${version}";
21     hash = "sha256-n1CME/swV+NsZdUfWwVY1qQeYzawwy+sm0mkRPQKm6A=";
22   };
24   propagatedBuildInputs = [
25     psutil
26     docopt
27   ];
29   postPatch = ''
30     substituteInPlace adbe/adb_enhanced.py \
31       --replace "cmd = 'java" "cmd = '${jdk11}/bin/java"
32   '';
34   # Disable tests because they require a dedicated Android emulator
35   doCheck = false;
37   pythonImportsCheck = [
38     "adbe"
39   ];
41   meta = with lib; {
42     description = "Tool for Android testing and development";
43     homepage = "https://github.com/ashishb/adb-enhanced";
44     sourceProvenance = with sourceTypes; [
45       fromSource
46       binaryBytecode
47     ];
48     license = licenses.asl20;
49     maintainers = with maintainers; [ vtuan10 ];
50     mainProgram = "adbe";
51   };