4d5a95770c
GitOrigin-RevId: 3c5319ad3aa51551182ac82ea17ab1c6b0f0df89
51 lines
1 KiB
Nix
51 lines
1 KiB
Nix
{ lib
|
|
, cython
|
|
, buildPythonPackage
|
|
, fetchFromGitHub
|
|
, poetry-core
|
|
, pytestCheckHook
|
|
, pythonOlder
|
|
, setuptools
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "ulid-transform";
|
|
version = "0.4.0";
|
|
format = "pyproject";
|
|
|
|
disabled = pythonOlder "3.9";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "bdraco";
|
|
repo = pname;
|
|
rev = "refs/tags/v${version}";
|
|
hash = "sha256-JuTIE8FAVZkfn+byJ1z9/ep9Oih1uXpz/QTB2OfM0WU=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
cython
|
|
poetry-core
|
|
setuptools
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
pytestCheckHook
|
|
];
|
|
|
|
postPatch = ''
|
|
substituteInPlace pyproject.toml \
|
|
--replace " --cov=ulid_transform --cov-report=term-missing:skip-covered" ""
|
|
'';
|
|
|
|
pythonImportsCheck = [
|
|
"ulid_transform"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "Library to create and transform ULIDs";
|
|
homepage = "https://github.com/bdraco/ulid-transform";
|
|
changelog = "https://github.com/bdraco/ulid-transform/releases/tag/v${version}";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
};
|
|
}
|