cli

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Apr 4, 2026 License: MIT Imports: 43 Imported by: 0

Documentation

Overview

Package cli implements the command-line interface for EchoWarp.

This package provides Cobra-based commands for:

  • Server mode: echowarp server
  • Client mode: echowarp client
  • Device listing: echowarp devices
  • Configuration: echowarp config
  • Daemon mode: echowarp daemon
  • Version info: echowarp version

The CLI is the primary user interface for EchoWarp operations.

Package cli provides the command-line interface for EchoWarp using Cobra. It defines subcommands for server, client, daemon, devices, config, update, and version.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRootCmd

func NewRootCmd() *cobra.Command

NewRootCmd creates the root command with all subcommands attached. The root command handles global flags and delegates to subcommands. When run without arguments it launches an interactive quick-start menu.

func RunDoctorToWriter

func RunDoctorToWriter(w io.Writer, address string, port int, tlsCertPath, _ string)

RunDoctorToWriter runs all diagnostics and writes results to w. This is the TUI-friendly version used by the quick-start menu result screen.

Types

type CheckResult

type CheckResult struct {
	Name    string      `json:"name"`
	Status  CheckStatus `json:"status"`
	Message string      `json:"message"`
}

CheckResult holds the result of a single diagnostic check.

type CheckStatus

type CheckStatus string

CheckStatus represents the status of a diagnostic check.

const (
	StatusOK   CheckStatus = "ok"
	StatusWarn CheckStatus = "warn"
	StatusFail CheckStatus = "fail"
)

type DoctorReport

type DoctorReport struct {
	Checks []CheckResult `json:"checks"`
}

DoctorReport holds all diagnostic check results.

func RunDoctorReport

func RunDoctorReport(address string, port int, tlsCertPath, cfgPath string) DoctorReport

RunDoctorReport runs all diagnostic checks and returns a structured report.

Jump to

Keyboard shortcuts

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