1{
2 lib,
3 appdirs,
4 buildPythonPackage,
5 fetchFromGitHub,
6 hatch-vcs,
7 hatchling,
8 pytest-mock,
9 pytestCheckHook,
10 pythonOlder,
11}:
12
13buildPythonPackage rec {
14 pname = "platformdirs";
15 version = "4.2.0";
16 format = "pyproject";
17
18 disabled = pythonOlder "3.7";
19
20 src = fetchFromGitHub {
21 owner = pname;
22 repo = pname;
23 rev = "refs/tags/${version}";
24 hash = "sha256-DjRqOIkyhkA3Z1gl2o78R4kp23qJBj+pRmDBld8AbDI=";
25 };
26
27 nativeBuildInputs = [
28 hatchling
29 hatch-vcs
30 ];
31
32 nativeCheckInputs = [
33 appdirs
34 pytest-mock
35 pytestCheckHook
36 ];
37
38 pythonImportsCheck = [ "platformdirs" ];
39
40 meta = with lib; {
41 description = "Module for determining appropriate platform-specific directories";
42 homepage = "https://platformdirs.readthedocs.io/";
43 changelog = "https://github.com/platformdirs/platformdirs/releases/tag/${version}";
44 license = licenses.mit;
45 maintainers = with maintainers; [ fab ];
46 };
47}