cli

package
v0.1.0-beta Latest Latest
Warning

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

Go to latest
Published: Mar 9, 2025 License: MIT Imports: 13 Imported by: 0

Documentation

Overview

Package cli provides the command-line interface for the application.

Package cli provides the command-line interface for the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRootCmd

func NewRootCmd(cfg *config.Config, version string, embeds embed.FS) (*cobra.Command, error)

NewRootCmd creates the root command with common configuration. It sets up environment variable binding and flag handling.

func NewRootCommand

func NewRootCommand(version string, cfg *config.Config, funcs ...func(*cobra.Command, []string) error) *cobra.Command

NewDefaultRootCommand creates a root command with default settings. It sets up integration with viper, with environment variable and flag binding. Additional functions can be passed to be executed before the command is run.

Types

type CommandFactory

type CommandFactory struct {
	// contains filtered or unexported fields
}

CommandFactory creates and configures commands.

func (*CommandFactory) CreateRootCommand

func (f *CommandFactory) CreateRootCommand() *cobra.Command

CreateRootCommand creates and configures the root command.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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