python312Packages.fnllm: 0.0.11 -> 0.0.12 (#364582)
[NixPkgs.git] / pkgs / development / python-modules / pdm-backend / default.nix
blobb7a7f87a4fd0aaaad9ff9a90e1a28e82161c2c9b
2   lib,
3   buildPythonPackage,
4   pythonOlder,
5   fetchFromGitHub,
7   # propagates
8   importlib-metadata,
10   # tests
11   editables,
12   git,
13   mercurial,
14   pytestCheckHook,
15   setuptools,
18 buildPythonPackage rec {
19   pname = "pdm-backend";
20   version = "2.4.3";
21   pyproject = true;
23   src = fetchFromGitHub {
24     owner = "pdm-project";
25     repo = "pdm-backend";
26     rev = "refs/tags/${version}";
27     hash = "sha256-XbHlzt00R0kB8I6nRvteAgpFlUTAvBcF5iaQD5V30ok=";
28   };
30   env.PDM_BUILD_SCM_VERSION = version;
32   dependencies = lib.optionals (pythonOlder "3.10") [ importlib-metadata ];
34   pythonImportsCheck = [ "pdm.backend" ];
36   nativeCheckInputs = [
37     editables
38     git
39     mercurial
40     pytestCheckHook
41     setuptools
42   ];
44   preCheck = ''
45     unset PDM_BUILD_SCM_VERSION
47     # tests require a configured git identity
48     export HOME=$TMPDIR
49     git config --global user.name nixbld
50     git config --global user.email nixbld@localhost
51   '';
53   setupHook = ./setup-hook.sh;
55   meta = with lib; {
56     homepage = "https://github.com/pdm-project/pdm-backend";
57     changelog = "https://github.com/pdm-project/pdm-backend/releases/tag/${version}";
58     description = "Yet another PEP 517 backend";
59     license = licenses.mit;
60     maintainers = with maintainers; [ hexa ];
61   };