cli

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2026 License: Apache-2.0 Imports: 31 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package cli implements the spackle command line: subcommand dispatch, flag parsing, help text and exit codes.

Index

Constants

View Source
const (
	ExitOK       = 0 // ran, nothing at or above the failure threshold
	ExitFindings = 1 // ran, findings at or above the failure threshold
	ExitUsage    = 2 // bad flags, bad config, or a refused target
	ExitError    = 3 // the run itself failed
)

Exit codes. They are part of the CLI contract (see docs/ci.md).

View Source
const AuthorizedUse = "Authorized use only. Point Spackle at systems you own or have written permission to test."

AuthorizedUse is shown at the top of help output and in the README.

Variables

This section is empty.

Functions

func Main

func Main(args []string, stdin io.Reader, stdout, stderr io.Writer) int

Main runs the CLI and returns the process exit code.

Types

type Env

type Env struct {
	Stdin  io.Reader
	Stdout io.Writer
	Stderr io.Writer
}

Env carries the process streams so commands are testable.

Jump to

Keyboard shortcuts

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