app

package
v1.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2024 License: Apache-2.0 Imports: 14 Imported by: 1

Documentation

Overview

Package app provides the functionality to generate SBOMs for applications.

Please refer to the CLI documentation for further details about this mode.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewGenerator

func NewGenerator(moduleDir string, opts ...Option) (generate.Generator, error)

Types

type Option

type Option func(g *generator) error

func WithIncludeFiles

func WithIncludeFiles(enable bool) Option

WithIncludeFiles toggles the inclusion of files. Has no effect when packages are not included as well.

func WithIncludePackages

func WithIncludePackages(enable bool) Option

WithIncludePackages toggles the inclusion of packages.

func WithIncludePaths added in v1.6.0

func WithIncludePaths(enable bool) Option

WithIncludePaths toggles the inclusion of file paths. Has no effect when files are not included as well.

func WithIncludeStdlib

func WithIncludeStdlib(enable bool) Option

WithIncludeStdlib toggles the inclusion of a std component representing the Go standard library in the generated BOM.

When enabled, the std component will be represented as a direct dependency of the main module.

func WithLicenseDetector

func WithLicenseDetector(detector licensedetect.Detector) Option

WithLicenseDetector sets the license detector.

When nil, no license detection will be performed. Default is nil.

func WithLogger

func WithLogger(logger zerolog.Logger) Option

WithLogger overrides the default logger of the generator.

func WithMainDir

func WithMainDir(dir string) Option

WithMainDir overrides the main directory of the application.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL