1a04744f74
There is no need to disable Python packages for Python versions that are
no longer in Nixpkgs.
This change was generated using the following script:
pattern='^\s*disabled\s*=\s*pythonOlder\s*"3\.\([0-9]\|10\)"\s*;\s*$'
for f in $(find -name '*.nix'); do
grep -q "$pattern" "$f" || continue
sed -i "/$pattern/d" "$f"
if [ $(grep -c pythonOlder "$f") == 1 ]; then
sed -i '/^\s*pythonOlder,\s*$/d' "$f"
fi
nixfmt "$f"
done
53 lines
1.0 KiB
Nix
53 lines
1.0 KiB
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchPypi,
|
|
setuptools,
|
|
pytestCheckHook,
|
|
pytest-cov-stub,
|
|
vcrpy,
|
|
citeproc-py,
|
|
looseversion,
|
|
requests,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "duecredit";
|
|
version = "0.10.2";
|
|
pyproject = true;
|
|
|
|
src = fetchPypi {
|
|
inherit pname version;
|
|
hash = "sha256-/nOiDk+7LZcroB7fN97BsLoeZG7+XvTMrwxnJMoofUI=";
|
|
};
|
|
|
|
nativeBuildInputs = [ setuptools ];
|
|
propagatedBuildInputs = [
|
|
citeproc-py
|
|
looseversion
|
|
requests
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
pytest-cov-stub
|
|
vcrpy
|
|
];
|
|
disabledTests = [ "test_import_doi" ]; # tries to access network
|
|
|
|
preCheck = ''
|
|
export HOME=$(mktemp -d)
|
|
'';
|
|
|
|
pythonImportsCheck = [ "duecredit" ];
|
|
|
|
meta = {
|
|
homepage = "https://github.com/duecredit/duecredit";
|
|
description = "Simple framework to embed references in code";
|
|
mainProgram = "duecredit";
|
|
changelog = "https://github.com/duecredit/duecredit/releases/tag/${version}";
|
|
license = lib.licenses.bsd2;
|
|
maintainers = [ lib.maintainers.bcdarwin ];
|
|
};
|
|
}
|