2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
setuptools,
|
|
|
|
build,
|
|
|
|
coloredlogs,
|
|
|
|
packaging,
|
|
|
|
pip,
|
|
|
|
readme-renderer,
|
|
|
|
toml,
|
|
|
|
twine,
|
2023-11-16 04:20:00 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "bork";
|
2024-04-21 15:54:59 +00:00
|
|
|
version = "8.0.0";
|
2023-11-16 04:20:00 +00:00
|
|
|
pyproject = true;
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "duckinator";
|
|
|
|
repo = pname;
|
2024-04-21 15:54:59 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
|
|
|
hash = "sha256-BDwVhKmZ/F8CvpT6dEI5moQZx8wHy1TwdOl889XogEo=";
|
2023-11-16 04:20:00 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
build-system = [
|
|
|
|
setuptools
|
2024-01-13 08:15:51 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
pythonRelaxDeps = [
|
2024-06-20 14:57:18 +00:00
|
|
|
"build"
|
2024-01-13 08:15:51 +00:00
|
|
|
"packaging"
|
2024-04-21 15:54:59 +00:00
|
|
|
"readme-renderer"
|
2024-01-13 08:15:51 +00:00
|
|
|
"twine"
|
|
|
|
"wheel"
|
|
|
|
];
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
dependencies = [
|
2023-11-16 04:20:00 +00:00
|
|
|
build
|
|
|
|
coloredlogs
|
|
|
|
packaging
|
2024-01-02 11:29:13 +00:00
|
|
|
pip
|
2024-04-21 15:54:59 +00:00
|
|
|
readme-renderer
|
2023-11-16 04:20:00 +00:00
|
|
|
twine
|
2024-06-05 15:53:02 +00:00
|
|
|
] ++ lib.optionals (pythonOlder "3.11") [ toml ];
|
2023-11-16 04:20:00 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [
|
|
|
|
"bork"
|
|
|
|
"bork.api"
|
|
|
|
"bork.cli"
|
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
2024-04-21 15:54:59 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pytestFlagsArray = [ "-m 'not network'" ];
|
2024-01-02 11:29:13 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
disabledTests = [
|
|
|
|
# tries to call python -m bork
|
|
|
|
"test_repo"
|
|
|
|
];
|
|
|
|
|
2023-11-16 04:20:00 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Python build and release management tool";
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "bork";
|
2023-11-16 04:20:00 +00:00
|
|
|
homepage = "https://github.com/duckinator/bork";
|
|
|
|
maintainers = with maintainers; [ nicoo ];
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|