2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, six
|
|
|
|
, pythonOlder
|
2021-04-26 19:14:03 +00:00
|
|
|
, scandir ? null
|
2020-04-24 23:36:52 +00:00
|
|
|
, glibcLocales
|
2022-04-15 01:41:22 +00:00
|
|
|
, mock
|
|
|
|
, typing
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pathlib2";
|
2022-04-15 01:41:22 +00:00
|
|
|
version = "2.3.7.post1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-04-15 01:41:22 +00:00
|
|
|
sha256 = "sha256-n+DtrYmLg8DD4ZnIQrJ+0hZkXS4Xd1ey3Wc4TUETxkE=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
propagatedBuildInputs = [ six ]
|
|
|
|
++ lib.optionals (pythonOlder "3.5") [ scandir typing ];
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [ glibcLocales ]
|
2022-04-15 01:41:22 +00:00
|
|
|
++ lib.optional (pythonOlder "3.3") mock;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
preCheck = ''
|
|
|
|
export LC_ALL="en_US.UTF-8"
|
|
|
|
'';
|
|
|
|
|
2022-04-15 01:41:22 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "This module offers classes representing filesystem paths with semantics appropriate for different operating systems.";
|
2022-04-15 01:41:22 +00:00
|
|
|
homepage = "https://pypi.org/project/pathlib2/";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ SuperSandro2000 ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|