1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 six,
6 pythonOlder,
7 scandir ? null,
8 typing,
9}:
10
11buildPythonPackage rec {
12 pname = "pathlib2";
13 version = "2.3.7.post1";
14 format = "setuptools";
15
16 src = fetchPypi {
17 inherit pname version;
18 hash = "sha256-n+DtrYmLg8DD4ZnIQrJ+0hZkXS4Xd1ey3Wc4TUETxkE=";
19 };
20
21 propagatedBuildInputs = [
22 six
23 ]
24 ++ lib.optionals (pythonOlder "3.5") [
25 scandir
26 typing
27 ];
28
29 meta = with lib; {
30 description = "This module offers classes representing filesystem paths with semantics appropriate for different operating systems";
31 homepage = "https://pypi.org/project/pathlib2/";
32 license = with licenses; [ mit ];
33 maintainers = [ ];
34 };
35}