depot/third_party/nixpkgs/pkgs/development/python-modules/nodeenv/default.nix
Default email ca5ab3a501 Project import generated by Copybara.
GitOrigin-RevId: 4a01ca36d6bfc133bc617e661916a81327c9bbc8
2022-07-14 08:49:19 -04:00

55 lines
1,003 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, mock
, pytestCheckHook
, python
, pythonOlder
, setuptools
, which
}:
buildPythonPackage rec {
pname = "nodeenv";
version = "1.7.0";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "ekalinin";
repo = pname;
rev = version;
hash = "sha256-X30PUiOMT/vXqmdSJKHTNNA8aLWavCUaKa7LzqkdLrk=";
};
propagatedBuildInputs = [
setuptools
];
checkInputs = [
mock
pytestCheckHook
];
preFixup = ''
substituteInPlace $out/${python.sitePackages}/nodeenv.py \
--replace '["which", candidate]' '["${lib.getBin which}/bin/which", candidate]'
'';
pythonImportsCheck = [
"nodeenv"
];
disabledTests = [
# Test requires coverage
"test_smoke"
];
meta = with lib; {
description = "Node.js virtual environment builder";
homepage = "https://github.com/ekalinin/nodeenv";
license = licenses.bsd3;
maintainers = with maintainers; [ ];
};
}