cmd

package
v0.9.4 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateContainerFromDaemon added in v0.9.4

func CreateContainerFromDaemon(task, parentContainer, branch string) (string, error)

CreateContainerFromDaemon creates a new child container from a daemon IPC request. This is called by the daemon when a container requests a sibling via maestro-request.

func CreateContainerFromTUI

func CreateContainerFromTUI(taskDescription, branchNameOverride string, skipConnect, exact bool) error

CreateContainerFromTUI creates a new container with the given parameters (called from TUI)

func EnsureDaemonRunning added in v0.9.3

func EnsureDaemonRunning()

EnsureDaemonRunning starts the daemon if it's not already running. This is called automatically when the TUI starts.

func Execute

func Execute()

Execute runs the root command

Types

type Config

type Config struct {
	Claude struct {
		ConfigPath  string `mapstructure:"config_path"`
		AuthPath    string `mapstructure:"auth_path"`
		DefaultMode string `mapstructure:"default_mode"`
	} `mapstructure:"claude"`

	Containers struct {
		Prefix    string `mapstructure:"prefix"`
		Image     string `mapstructure:"image"`
		Resources struct {
			Memory string `mapstructure:"memory"`
			CPUs   string `mapstructure:"cpus"`
		} `mapstructure:"resources"`
		DefaultReturnToTUI bool `mapstructure:"default_return_to_tui"`
	} `mapstructure:"containers"`

	Tmux struct {
		DefaultSession string `mapstructure:"default_session"`
		Prefix         string `mapstructure:"prefix"`
	} `mapstructure:"tmux"`

	Firewall struct {
		AllowedDomains  []string `mapstructure:"allowed_domains"`
		InternalDNS     string   `mapstructure:"internal_dns"`
		InternalDomains []string `mapstructure:"internal_domains"`
	} `mapstructure:"firewall"`

	Sync struct {
		AdditionalFolders []string `mapstructure:"additional_folders"`
		Compress          *bool    `mapstructure:"compress"` // Use gzip compression when copying (default: true)
	} `mapstructure:"sync"`

	SSH struct {
		Enabled        bool   `mapstructure:"enabled"`
		KnownHostsPath string `mapstructure:"known_hosts_path"`
	} `mapstructure:"ssh"`

	SSL struct {
		CertificatesPath string `mapstructure:"certificates_path"`
	} `mapstructure:"ssl"`

	Android struct {
		SDKPath string `mapstructure:"sdk_path"`
	} `mapstructure:"android"`

	Git struct {
		UserName  string `mapstructure:"user_name"`
		UserEmail string `mapstructure:"user_email"`
	} `mapstructure:"git"`

	GitHub struct {
		Enabled    bool   `mapstructure:"enabled"`
		ConfigPath string `mapstructure:"config_path"`
		Hostname   string `mapstructure:"hostname"` // For GitHub Enterprise (e.g., git.int.avast.com)
	} `mapstructure:"github"`

	AWS struct {
		Enabled bool   `mapstructure:"enabled"`
		Profile string `mapstructure:"profile"`
		Region  string `mapstructure:"region"`
	} `mapstructure:"aws"`

	Bedrock struct {
		Enabled bool   `mapstructure:"enabled"`
		Model   string `mapstructure:"model"`
	} `mapstructure:"bedrock"`

	Daemon struct {
		CheckInterval string `mapstructure:"check_interval"`
		ShowNag       bool   `mapstructure:"show_nag"`
		TokenRefresh  struct {
			Enabled   bool   `mapstructure:"enabled"`
			Threshold string `mapstructure:"threshold"`
		} `mapstructure:"token_refresh"`
		Notifications struct {
			Enabled            bool     `mapstructure:"enabled"`
			AttentionThreshold string   `mapstructure:"attention_threshold"`
			NotifyOn           []string `mapstructure:"notify_on"`
			QuietHours         struct {
				Start string `mapstructure:"start"`
				End   string `mapstructure:"end"`
			} `mapstructure:"quiet_hours"`
		} `mapstructure:"notifications"`
	} `mapstructure:"daemon"`

	Apps map[string]string `mapstructure:"apps"` // name -> source path
}

Config represents the maestro configuration

type ContainerResult added in v0.9.3

type ContainerResult struct {
	TaskNumber int
	TaskTitle  string
	Success    bool
	Message    string
}

ContainerResult holds the result of creating a container

type ContainerSetupOptions added in v0.9.4

type ContainerSetupOptions struct {
	ContainerName   string
	BranchName      string
	Prompt          string            // Task prompt sent to Claude
	ExactPrompt     bool              // If true, prompt passed to Claude as-is (no planning wrapper)
	Labels          map[string]string // Docker labels (e.g., maestro.parent)
	ParentContainer string            // If set: copy workspace from this container instead of host cwd
	SourceBranch    string            // If set (with ParentContainer): checkout this branch after copy
}

ContainerSetupOptions holds all parameters for the shared container setup pipeline.

type MultiProgress added in v0.9.3

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

MultiProgress manages a multi-line progress display (like docker pull)

func GetMultiProgress added in v0.9.3

func GetMultiProgress() *MultiProgress

GetMultiProgress returns the global progress display

func InitMultiProgress added in v0.9.3

func InitMultiProgress() *MultiProgress

InitMultiProgress initializes the global multi-progress display

func (*MultiProgress) AddItem added in v0.9.3

func (mp *MultiProgress) AddItem(name string, totalSize int64)

AddItem adds a new item to track

func (*MultiProgress) CompleteItem added in v0.9.3

func (mp *MultiProgress) CompleteItem(name string)

CompleteItem marks an item as done

func (*MultiProgress) ErrorItem added in v0.9.3

func (mp *MultiProgress) ErrorItem(name string, err error)

ErrorItem marks an item as failed

func (*MultiProgress) Start added in v0.9.3

func (mp *MultiProgress) Start()

Start begins the progress display loop

func (*MultiProgress) StartItem added in v0.9.3

func (mp *MultiProgress) StartItem(name string)

StartItem marks an item as started

func (*MultiProgress) Stop added in v0.9.3

func (mp *MultiProgress) Stop()

Stop stops the progress display and renders final state

func (*MultiProgress) UpdateItem added in v0.9.3

func (mp *MultiProgress) UpdateItem(name string, bytesRead int64)

UpdateItem updates bytes read for an item

type ProgressItem added in v0.9.3

type ProgressItem struct {
	Name      string
	Status    string // "waiting", "copying", "done", "error"
	BytesRead int64
	TotalSize int64
	StartTime time.Time
	EndTime   time.Time
}

type Task added in v0.9.3

type Task struct {
	Number      int    `json:"number"`
	Title       string `json:"title"`
	Description string `json:"description"`
}

Task represents a single task extracted from the markdown file

Jump to

Keyboard shortcuts

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