2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
2022-01-03 16:56:52 +00:00
|
|
|
, chardet
|
|
|
|
, cryptography
|
|
|
|
, feedparser
|
2020-04-24 23:36:52 +00:00
|
|
|
, fetchPypi
|
2022-01-03 16:56:52 +00:00
|
|
|
, mock
|
|
|
|
, pysocks
|
|
|
|
, pytestCheckHook
|
|
|
|
, python-dateutil
|
|
|
|
, python-gnupg
|
|
|
|
, pythonOlder
|
|
|
|
, pytz
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "limnoria";
|
2023-08-22 20:05:09 +00:00
|
|
|
version = "2023.8.10";
|
2022-01-03 16:56:52 +00:00
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2023-08-22 20:05:09 +00:00
|
|
|
hash = "sha256-3AHc7Ej0IJ2WCQ8XVbWL0lwTQW6ng2ehemTcmJOQ86U=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-01-03 16:56:52 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
chardet
|
|
|
|
cryptography
|
|
|
|
feedparser
|
|
|
|
mock
|
|
|
|
pysocks
|
|
|
|
python-dateutil
|
|
|
|
python-gnupg
|
|
|
|
] ++ lib.optionals (pythonOlder "3.9") [
|
|
|
|
pytz
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-01-03 16:56:52 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
2021-08-27 14:25:00 +00:00
|
|
|
postPatch = ''
|
2022-01-03 16:56:52 +00:00
|
|
|
substituteInPlace setup.py \
|
|
|
|
--replace "version=version" 'version="${version}"'
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2022-01-03 16:56:52 +00:00
|
|
|
checkPhase = ''
|
|
|
|
runHook preCheck
|
|
|
|
export PATH="$PATH:$out/bin";
|
|
|
|
supybot-test test -v --no-network
|
|
|
|
runHook postCheck
|
|
|
|
'';
|
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
# Uses the same names as Supybot
|
|
|
|
"supybot"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A modified version of Supybot, an IRC bot";
|
|
|
|
homepage = "https://github.com/ProgVal/Limnoria";
|
|
|
|
license = licenses.bsd3;
|
|
|
|
maintainers = with maintainers; [ goibhniu ];
|
|
|
|
};
|
|
|
|
}
|