a0cb138ada
GitOrigin-RevId: a100acd7bbf105915b0004427802286c37738fef
46 lines
841 B
Nix
46 lines
841 B
Nix
{ lib
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
|
|
# native
|
|
, flake8
|
|
|
|
# tests
|
|
, pytestCheckHook
|
|
, pexpect
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "readchar";
|
|
version = "4.0.3";
|
|
format = "setuptools";
|
|
|
|
# Don't use wheels on PyPI
|
|
src = fetchFromGitHub {
|
|
owner = "magmax";
|
|
repo = "python-${pname}";
|
|
rev = "refs/tags/v${version}";
|
|
sha256 = "sha256-QMaTZRS9iOSuax706Es9WhkwU3vdcNb14dbiSt48aN0=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace setup.cfg \
|
|
--replace "--cov=readchar" ""
|
|
'';
|
|
|
|
nativeBuildInputs = [
|
|
flake8
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
pexpect
|
|
];
|
|
|
|
meta = with lib; {
|
|
homepage = "https://github.com/magmax/python-readchar";
|
|
description = "Python library to read characters and key strokes";
|
|
license = licenses.mit;
|
|
maintainers = [ maintainers.mmahut ];
|
|
};
|
|
}
|