depot/third_party/nixpkgs/pkgs/development/python-modules/zimports/default.nix
Default email bb584b27e9 Project import generated by Copybara.
GitOrigin-RevId: 5181d5945eda382ff6a9ca3e072ed6ea9b547fee
2022-04-15 03:41:22 +02:00

46 lines
842 B
Nix

{ lib
, isPy3k
, fetchFromGitHub
, buildPythonPackage
, flake8-import-order
, pyflakes
, mock
, setuptools
}:
buildPythonPackage rec {
pname = "zimports";
version = "0.5.0";
src = fetchFromGitHub {
owner = "sqlalchemyorg";
repo = "zimports";
rev = "v${version}";
sha256 = "sha256-O8MHUt9yswL9fK9pEddkvnNS2E4vWA/S1BTs1OD1VbU=";
};
disabled = !isPy3k;
propagatedBuildInputs = [
pyflakes
flake8-import-order
setuptools
];
checkInputs = [
mock
];
checkPhase = ''
runHook preInstallCheck
PYTHONPATH= $out/bin/zimports --help >/dev/null
runHook postInstallCheck
'';
meta = with lib; {
description = "Python import rewriter";
homepage = "https://github.com/sqlalchemyorg/zimports";
license = licenses.mit;
maintainers = with maintainers; [ timokau ];
};
}