mix lei.sbom (LowEndInsight v0.13.1)

Copy Markdown View Source

Analyze a git repository and produce an SBOM in CycloneDX 1.4 or SPDX 2.3 JSON format. Bus-factor risk scores from LowEndInsight are embedded as custom properties.

Usage

mix lei.sbom <repo_url> [--format cyclonedx|spdx] [--output <file>]

Options

  • --format - SBOM format: cyclonedx (default) or spdx
  • --output - Write output to file instead of stdout

Examples

mix lei.sbom "https://github.com/kitplummer/xmpp4rails"
mix lei.sbom "https://github.com/kitplummer/xmpp4rails" --format spdx
mix lei.sbom "https://github.com/kitplummer/xmpp4rails" --format cyclonedx --output bom.json

Summary

Functions

Reads the arguments, refusing a bad one before any work is done.

Functions

parse_args(args)

@spec parse_args([String.t()]) :: {:ok, map()} | {:error, String.t()}

Reads the arguments, refusing a bad one before any work is done.

The format used to be checked after the repository had been analysed, so a typo cost a full clone before saying so.