depot/third_party/nixpkgs/pkgs/development/python-modules/supervise-api/default.nix
Default email bcb2f287e1 Project import generated by Copybara.
GitOrigin-RevId: d603719ec6e294f034936c0d0dc06f689d91b6c3
2024-06-20 20:27:18 +05:30

40 lines
878 B
Nix

{
lib,
buildPythonPackage,
fetchPypi,
substituteAll,
supervise,
setuptools,
pytestCheckHook,
}:
buildPythonPackage rec {
pname = "supervise-api";
version = "0.6.0";
pyproject = true;
src = fetchPypi {
pname = "supervise_api";
inherit version;
hash = "sha256-EjD0IpSRDoNCG307CKlo0n1RCkpwnpZlB+1w212hud4=";
};
postPatch = ''
substituteInPlace supervise_api/supervise.py \
--replace 'which("supervise")' '"${supervise}/bin/supervise"'
'';
nativeBuildInputs = [ setuptools ];
nativeCheckInputs = [ pytestCheckHook ];
pythonImportsCheck = [ "supervise_api" ];
meta = {
description = "API for running processes safely and securely";
homepage = "https://github.com/catern/supervise";
license = lib.licenses.mit;
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ catern ];
};
}