cmd

package
v0.27.0 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2026 License: Apache-2.0 Imports: 265 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Execute

func Execute()

Execute adds all child commands to the root command and sets flags appropriately. This is called by main.main(). It only needs to happen once to the rootCmd.

func ProcessValue added in v0.27.0

func ProcessValue(v any, isToolset bool) any

ProcessValue recursively looks for MapSlices to rename 'kind' -> 'type'

Types

type Command

type Command struct {
	*cobra.Command
	// contains filtered or unexported fields
}

Command represents an invocation of the CLI.

func NewCommand

func NewCommand(opts ...Option) *Command

NewCommand returns a Command object representing an invocation of the CLI.

func (*Command) Config added in v0.27.0

func (cmd *Command) Config() server.ServerConfig

func (*Command) LoadConfig added in v0.27.0

func (cmd *Command) LoadConfig(ctx context.Context) error

func (*Command) Logger added in v0.27.0

func (cmd *Command) Logger() log.Logger

func (*Command) Out added in v0.27.0

func (cmd *Command) Out() io.Writer

func (*Command) Setup added in v0.27.0

func (cmd *Command) Setup(ctx context.Context) (context.Context, func(context.Context) error, error)

type Option added in v0.0.3

type Option func(*Command)

Option is a function that configures a Command.

func WithStreams added in v0.0.3

func WithStreams(out, err io.Writer) Option

WithStreams overrides the default writer.

type ToolsFile added in v0.0.4

type ToolsFile struct {
	Sources         server.SourceConfigs         `yaml:"sources"`
	AuthServices    server.AuthServiceConfigs    `yaml:"authServices"`
	EmbeddingModels server.EmbeddingModelConfigs `yaml:"embeddingModels"`
	Tools           server.ToolConfigs           `yaml:"tools"`
	Toolsets        server.ToolsetConfigs        `yaml:"toolsets"`
	Prompts         server.PromptConfigs         `yaml:"prompts"`
}

Jump to

Keyboard shortcuts

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