2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
2021-08-18 13:19:15 +00:00
|
|
|
, appdirs
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, cachelib
|
2021-08-18 13:19:15 +00:00
|
|
|
, cssselect
|
|
|
|
, fetchFromGitHub
|
2020-09-25 04:45:31 +00:00
|
|
|
, keep
|
2021-08-18 13:19:15 +00:00
|
|
|
, lxml
|
|
|
|
, pygments
|
|
|
|
, pyquery
|
|
|
|
, requests
|
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "howdoi";
|
2021-10-28 06:52:43 +00:00
|
|
|
version = "2.0.19";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-08-18 13:19:15 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "gleitz";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-10-28 06:52:43 +00:00
|
|
|
sha256 = "0hl7cpxm4llsgw6390bpjgkzrprrpb0vxx2flgly7wiy9zl1rc5q";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-08-18 13:19:15 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
appdirs
|
|
|
|
cachelib
|
|
|
|
cssselect
|
|
|
|
keep
|
|
|
|
lxml
|
|
|
|
pygments
|
|
|
|
pyquery
|
|
|
|
requests
|
|
|
|
];
|
2020-09-25 04:45:31 +00:00
|
|
|
|
2021-08-18 13:19:15 +00:00
|
|
|
checkInputs = [
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
preCheck = ''
|
|
|
|
export HOME=$(mktemp -d)
|
|
|
|
'';
|
2021-08-18 13:19:15 +00:00
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# AssertionError: "The...
|
|
|
|
"test_get_text_with_one_link"
|
|
|
|
"test_get_text_without_links"
|
|
|
|
];
|
|
|
|
|
2021-10-28 06:52:43 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"howdoi"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Instant coding answers via the command line";
|
|
|
|
homepage = "https://pypi.python.org/pypi/howdoi";
|
|
|
|
license = licenses.mit;
|
2021-08-18 13:19:15 +00:00
|
|
|
maintainers = with maintainers; [ costrouc ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|