nixpkgs/pkgs/development/python-modules/cvelib/default.nix
Martin Weinelt 8056f9250c
treewide: remove redundant SETUPTOOLS_SCM_PRETEND_VERSION usage
The setuptools-scm packages gained a setup hook, that sets it to the
derivation version automatically, so setting it to that manually has
become redundant.

This also affects downstream consumers of setuptools-scm, like hatch-vcs
or flit-scm.
2023-12-20 20:16:39 +01:00

51 lines
951 B
Nix

{ lib
, buildPythonPackage
, click
, fetchFromGitHub
, jsonschema
, pytestCheckHook
, pythonOlder
, requests
, testers
, cve
}:
buildPythonPackage rec {
pname = "cvelib";
version = "1.2.1";
format = "setuptools";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "RedHatProductSecurity";
repo = "cvelib";
rev = "tags/${version}";
hash = "sha256-hJPcxnc4iQzsYNNVJ9fw6yQl+5K7pdtjHT6oMmBx/Zs=";
};
propagatedBuildInputs = [
click
jsonschema
requests
];
nativeCheckInputs = [
pytestCheckHook
];
pythonImportsCheck = [
"cvelib"
];
passthru.tests.version = testers.testVersion { package = cve; };
meta = with lib; {
description = "Library and a command line interface for the CVE Services API";
homepage = "https://github.com/RedHatProductSecurity/cvelib";
license = licenses.mit;
maintainers = with maintainers; [ raboof ];
mainProgram = "cve";
};
}