2019-09-10 18:37:39 +01:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi, fetchpatch, six
|
|
|
|
, wcwidth, pytest, mock, glibcLocales
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
|
|
|
|
fixTestSuiteFailure_1 = fetchpatch {
|
2020-04-01 02:11:51 +01:00
|
|
|
url = "https://github.com/jquast/blessed/pull/108/commits/76a54d39b0f58bfc71af04ee143459eefb0e1e7b.patch";
|
2019-09-10 18:37:39 +01:00
|
|
|
sha256 = "1higmv4c03ly7ywac1d7s71f3hrl531vj16nsfl9xh6zh9c47qcg";
|
|
|
|
};
|
|
|
|
|
|
|
|
fixTestSuiteFailure_2 = fetchpatch {
|
2020-04-01 02:11:51 +01:00
|
|
|
url = "https://github.com/jquast/blessed/pull/108/commits/aa94e01aed745715e667601fb674844b257cfcc9.patch";
|
2019-09-10 18:37:39 +01:00
|
|
|
sha256 = "1frygr6sc1vakdfx1hf6jj0dbwibiqz8hw9maf1b605cbslc9nay";
|
|
|
|
};
|
|
|
|
|
|
|
|
in
|
2017-09-01 12:38:22 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "blessed";
|
2018-06-21 06:37:16 +01:00
|
|
|
version = "1.15.0";
|
2017-09-01 12:38:22 +01:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2018-06-21 06:37:16 +01:00
|
|
|
sha256 = "777b0b6b5ce51f3832e498c22bc6a093b6b5f99148c7cbf866d26e2dec51ef21";
|
2017-09-01 12:38:22 +01:00
|
|
|
};
|
|
|
|
|
2019-09-10 18:37:39 +01:00
|
|
|
patches = [ fixTestSuiteFailure_1 fixTestSuiteFailure_2 ];
|
|
|
|
|
2017-12-14 22:32:26 +00:00
|
|
|
checkInputs = [ pytest mock glibcLocales ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
2019-09-10 21:20:35 +01:00
|
|
|
LANG=en_US.utf-8 py.test blessed/tests
|
2017-12-14 22:32:26 +00:00
|
|
|
'';
|
|
|
|
|
2017-09-01 12:38:22 +01:00
|
|
|
propagatedBuildInputs = [ wcwidth six ];
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/jquast/blessed";
|
2017-09-01 12:38:22 +01:00
|
|
|
description = "A thin, practical wrapper around terminal capabilities in Python.";
|
|
|
|
maintainers = with maintainers; [ eqyiel ];
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
}
|