state

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AgentState

type AgentState struct {
	GitRepo      string    `json:"git_repo"`
	BranchFrom   string    `json:"branch_from"`
	BranchName   string    `json:"branch_name"`
	Prompt       string    `json:"prompt"`
	WorktreePath string    `json:"worktree_path"`
	Port         int       `json:"port,omitempty"`
	Model        string    `json:"model"`
	CreatedAt    time.Time `json:"created_at"`
	UpdatedAt    time.Time `json:"updated_at"`
}

type StateManager

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

func NewStateManager

func NewStateManager() *StateManager

func (*StateManager) GetActiveSessionsForRepo

func (sm *StateManager) GetActiveSessionsForRepo() ([]string, error)

func (*StateManager) GetStatePath

func (sm *StateManager) GetStatePath() string

func (*StateManager) GetWorktreeInfo

func (sm *StateManager) GetWorktreeInfo(sessionName string) (*AgentState, error)

GetWorktreeInfo returns the worktree information for a given session

func (*StateManager) RemoveState

func (sm *StateManager) RemoveState(sessionName string) error

func (*StateManager) SaveState

func (sm *StateManager) SaveState(prompt, branchName, sessionName, worktreePath, model string) error

func (*StateManager) SaveStateWithPort

func (sm *StateManager) SaveStateWithPort(prompt, branchName, sessionName, worktreePath, model string, port int) error

Jump to

Keyboard shortcuts

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