2024-05-15 15:35:15 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchFromGitHub,
|
|
|
|
poetry-core,
|
2024-07-27 06:49:29 +00:00
|
|
|
|
|
|
|
# dependencies
|
|
|
|
attrs,
|
2024-05-15 15:35:15 +00:00
|
|
|
binaryornot,
|
|
|
|
boolean-py,
|
|
|
|
debian,
|
|
|
|
jinja2,
|
|
|
|
license-expression,
|
2024-07-27 06:49:29 +00:00
|
|
|
tomlkit,
|
|
|
|
|
|
|
|
# test dependencies
|
|
|
|
freezegun,
|
2024-05-15 15:35:15 +00:00
|
|
|
pytestCheckHook,
|
2024-01-02 11:29:13 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
buildPythonPackage rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "reuse";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "4.0.3";
|
2024-05-15 15:35:15 +00:00
|
|
|
pyproject = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fsfe";
|
|
|
|
repo = "reuse-tool";
|
2023-02-16 17:41:37 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
hash = "sha256-oKtQBT8tuAk4S/Sygp4qxLk4ADWDTG0MbVaL5O2qsuA=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [ poetry-core ];
|
2022-12-17 10:02:37 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
dependencies = [
|
2024-07-27 06:49:29 +00:00
|
|
|
attrs
|
2020-04-24 23:36:52 +00:00
|
|
|
binaryornot
|
|
|
|
boolean-py
|
|
|
|
debian
|
|
|
|
jinja2
|
|
|
|
license-expression
|
2024-07-27 06:49:29 +00:00
|
|
|
tomlkit
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
nativeCheckInputs = [ pytestCheckHook freezegun ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-08-04 22:07:22 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# pytest wants to execute the actual source files for some reason, which fails with ImportPathMismatchError()
|
|
|
|
"src/reuse"
|
|
|
|
];
|
|
|
|
|
2024-01-02 11:29:13 +00:00
|
|
|
pythonImportsCheck = [ "reuse" ];
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = with lib; {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Tool for compliance with the REUSE Initiative recommendations";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/fsfe/reuse-tool";
|
2024-05-15 15:35:15 +00:00
|
|
|
changelog = "https://github.com/fsfe/reuse-tool/blob/v${version}/CHANGELOG.md";
|
|
|
|
license = with licenses; [
|
|
|
|
asl20
|
|
|
|
cc-by-sa-40
|
|
|
|
cc0
|
|
|
|
gpl3Plus
|
|
|
|
];
|
|
|
|
maintainers = with maintainers; [
|
|
|
|
FlorianFranzen
|
|
|
|
Luflosi
|
|
|
|
];
|
2024-01-02 11:29:13 +00:00
|
|
|
mainProgram = "reuse";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|