cli

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package cli wires the cobra command tree for mcpbench.

Index

Constants

This section is empty.

Variables

View Source
var ErrRegression = errSentinel("mcpbench: regression detected")

ErrRegression is returned by the compare command when one or more thresholds are exceeded. main.go translates this to exit code 1 without printing a duplicate message.

View Source
var Version = "0.1.0"

Version is the mcpbench CLI version. Set via -ldflags during build.

Functions

func Execute

func Execute(args []string, stdout, stderr io.Writer) error

Execute runs the root command, directing I/O to the provided streams. It returns an error rather than calling os.Exit so that callers (and tests) can decide how to surface the failure.

func NewCompareCmd

func NewCompareCmd() *cobra.Command

NewCompareCmd builds the `mcpbench compare` subcommand.

func NewRootCmd

func NewRootCmd() *cobra.Command

NewRootCmd builds the top-level cobra command.

func NewRunCmd

func NewRunCmd() *cobra.Command

NewRunCmd builds the `mcpbench run` subcommand.

func NewScenarioValidateCmd

func NewScenarioValidateCmd() *cobra.Command

NewScenarioValidateCmd builds the `mcpbench scenario-validate` subcommand.

func NewVersionCmd

func NewVersionCmd() *cobra.Command

NewVersionCmd prints the CLI version.

Types

This section is empty.

Jump to

Keyboard shortcuts

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