sbom4python: init at 0.12.1 (#378227)

This commit is contained in:
Pol Dellaiera 2025-02-01 08:56:40 +01:00 committed by GitHub
commit 6eec6bbb93
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 196 additions and 0 deletions

View File

@ -0,0 +1,7 @@
{
python3Packages,
}:
(python3Packages.toPythonApplication python3Packages.sbom2dot).overrideAttrs (previousAttrs: {
meta.mainProgram = "sbom2dot";
})

View File

@ -0,0 +1,7 @@
{
python3Packages,
}:
(python3Packages.toPythonApplication python3Packages.sbom4files).overrideAttrs (previousAttrs: {
meta.mainProgram = "sbom4files";
})

View File

@ -0,0 +1,53 @@
{
lib,
python3Packages,
fetchFromGitHub,
sbom2dot,
sbom4files,
versionCheckHook,
}:
python3Packages.buildPythonApplication rec {
pname = "sbom4python";
version = "0.12.1";
pyproject = true;
src = fetchFromGitHub {
owner = "anthonyharrison";
repo = "sbom4python";
tag = "v${version}";
hash = "sha256-tp5sg3Z3tczWxfYQcpeKMlin1s7PGUqjG3h4ZsAfKHs=";
};
build-system = with python3Packages; [
setuptools
];
dependencies = with python3Packages; [
importlib-metadata
lib4package
lib4sbom
sbom2dot
sbom4files
setuptools # for pkg_resources
toml
];
nativeCheckInputs = [
versionCheckHook
];
versionCheckProgramArg = [ "--version" ];
pythonImportsCheck = [
"sbom4python"
];
meta = {
changelog = "https://github.com/anthonyharrison/sbom4python/releases/tag/v${version}";
description = "A tool to generate a SBOM (Software Bill of Materials) for an installed Python module";
homepage = "https://github.com/anthonyharrison/sbom4python";
license = lib.licenses.asl20;
mainProgram = "sbom4python";
maintainers = with lib.maintainers; [ drupol ];
};
}

View File

@ -0,0 +1,40 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
requests,
}:
buildPythonPackage rec {
pname = "lib4package";
version = "0.3.1";
pyproject = true;
src = fetchFromGitHub {
owner = "anthonyharrison";
repo = "lib4package";
tag = "v${version}";
hash = "sha256-ZU5Lne2/xBgaFrTumWpZsuL9ckqdACrb0iRraWo+Rk0=";
};
build-system = [
setuptools
];
dependencies = [
requests
];
pythonImportsCheck = [
"lib4package"
];
meta = {
changelog = "https://github.com/anthonyharrison/lib4package/releases/tag/v${version}";
description = "Utility for handling package metadata to include in Software Bill of Materials (SBOMs";
homepage = "https://github.com/anthonyharrison/lib4package";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ drupol ];
};
}

View File

@ -0,0 +1,41 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
lib4sbom,
}:
buildPythonPackage rec {
pname = "sbom2dot";
version = "0.3.1";
pyproject = true;
src = fetchFromGitHub {
owner = "anthonyharrison";
repo = "sbom2dot";
tag = "v${version}";
hash = "sha256-xrphhTbIyqe0CqQOpJSyzTWbGYFFOKdyWJTTAlURkoo=";
};
build-system = [
setuptools
];
dependencies = [
lib4sbom
];
pythonImportsCheck = [
"sbom2dot"
];
meta = {
changelog = "https://github.com/anthonyharrison/sbom2dot/releases/tag/v${version}";
description = "Create a dependency graph of the components within a SBOM";
homepage = "https://github.com/anthonyharrison/sbom2dot";
license = lib.licenses.asl20;
mainProgram = "sbom2dot";
maintainers = with lib.maintainers; [ drupol ];
};
}

View File

@ -0,0 +1,42 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,
setuptools,
lib4sbom,
python-magic,
}:
buildPythonPackage rec {
pname = "sbom4files";
version = "0.4.5";
pyproject = true;
src = fetchFromGitHub {
owner = "anthonyharrison";
repo = "sbom4files";
tag = "v${version}";
hash = "sha256-2J3JNFtau7U5mNkqxU8Y8wIg2JR7CUZUVX0A4F9tMLs=";
};
build-system = [
setuptools
];
dependencies = [
lib4sbom
python-magic
];
pythonImportsCheck = [
"sbom4files"
];
meta = {
changelog = "https://github.com/anthonyharrison/sbom4files/releases/tag/v${version}";
description = "SBOM generator for files within a directory";
homepage = "https://github.com/anthonyharrison/sbom4files";
license = lib.licenses.asl20;
maintainers = with lib.maintainers; [ drupol ];
};
}

View File

@ -7268,6 +7268,8 @@ self: super: with self; {
inherit python;
});
lib4package = callPackage ../development/python-modules/lib4package { };
libagent = callPackage ../development/python-modules/libagent { };
pa-ringbuffer = callPackage ../development/python-modules/pa-ringbuffer { };
@ -14518,6 +14520,10 @@ self: super: with self; {
sasmodels = callPackage ../development/python-modules/sasmodels { };
sbom2dot = callPackage ../development/python-modules/sbom2dot { };
sbom4files = callPackage ../development/python-modules/sbom4files { };
scalene = callPackage ../development/python-modules/scalene { };
scales = callPackage ../development/python-modules/scales { };