Versions in this module Expand all Collapse all v0 v0.27.1 Sep 16, 2025 Changes in this version + var ErrArgumentEmpty = errors.New("argument cannot be empty") + var ErrBranchNameContainsColon = errors.New("branch name contains invalid character ':'") + var ErrDeletionCancelled = errors.New("deletion cancelled by user") + var ErrDirectoryExists = errors.New("worktree directory already exists") + var ErrDuplicateRepository = errors.New("duplicate repository") + var ErrFailedToCloneRepository = errors.New("failed to clone repository") + var ErrFailedToDetectDefaultBranch = errors.New("failed to detect default branch") + var ErrFailedToExpandRepositoriesDir = errors.New("failed to expand repositories directory") + var ErrFailedToInitializeRepository = errors.New("failed to initialize repository in CM") + var ErrFailedToLoadRepositories = errors.New("failed to load repositories from status file") + var ErrGitRepositoryInvalid = errors.New("not a valid Git repository") + var ErrGitRepositoryNotFound = errors.New("not a valid Git repository: .git directory not found") + var ErrInvalidRepository = errors.New("invalid repository") + var ErrInvalidRepositoryName = errors.New("invalid repository name") + var ErrInvalidWorkspaceName = errors.New("invalid workspace name") + var ErrNoGitRepositoryOrWorkspaceFound = errors.New("no Git repository or workspace found") + var ErrNotInitialized = errors.New("CM is not initialized") + var ErrOriginRemoteInvalidURL = errors.New("origin remote URL is not a valid Git hosting service URL") + var ErrOriginRemoteNotFound = errors.New("origin remote not found or invalid") + var ErrPathResolution = errors.New("path resolution failed") + var ErrRepositoryAddition = errors.New("failed to add repository to status file") + var ErrRepositoryExists = errors.New("repository already exists") + var ErrRepositoryNotClean = errors.New("repository is not in a clean state") + var ErrRepositoryNotFound = errors.New("repository not found") + var ErrRepositoryURLEmpty = errors.New("repository URL cannot be empty") + var ErrStatusUpdate = errors.New("status file update failed") + var ErrUnsupportedRepositoryURLFormat = errors.New("unsupported repository URL format") + var ErrWorkspaceAlreadyExists = errors.New("workspace already exists") + var ErrWorkspaceModeNotSupported = errors.New("workspace mode not yet supported for load command") + var ErrWorkspaceNotFound = errors.New("workspace not found") + var ErrWorktreeExists = errors.New("worktree already exists for this branch") + var ErrWorktreeNotInStatus = errors.New("worktree not found in status file") + type CloneOpts struct + Recursive bool + type CodeManager interface + Clone func(repoURL string, opts ...CloneOpts) error + CreateWorkTree func(branch string, opts ...CreateWorkTreeOpts) error + CreateWorkspace func(params CreateWorkspaceParams) error + DeleteAllWorktrees func(force bool, opts ...DeleteAllWorktreesOpts) error + DeleteRepository func(params DeleteRepositoryParams) error + DeleteWorkTree func(branch string, force bool, opts ...DeleteWorktreeOpts) error + DeleteWorkTrees func(branches []string, force bool) error + DeleteWorkspace func(params DeleteWorkspaceParams) error + Init func(opts InitOpts) error + ListRepositories func() ([]RepositoryInfo, error) + ListWorkspaces func() ([]WorkspaceInfo, error) + ListWorktrees func(opts ...ListWorktreesOpts) ([]status.WorktreeInfo, error) + LoadWorktree func(branchArg string, opts ...LoadWorktreeOpts) error + OpenWorktree func(worktreeName, ideName string, opts ...OpenWorktreeOpts) error + SetLogger func(logger logger.Logger) + func NewCodeManager(params NewCodeManagerParams) (CodeManager, error) + type CreateWorkTreeOpts struct + Force bool + IDEName string + IssueRef string + Remote string + RepositoryName string + WorkspaceName string + type CreateWorkspaceParams struct + Repositories []string + WorkspaceName string + type DeleteAllWorktreesOpts struct + RepositoryName string + WorkspaceName string + type DeleteRepositoryParams struct + Force bool + RepositoryName string + type DeleteWorkspaceParams struct + Force bool + WorkspaceName string + type DeleteWorktreeOpts struct + RepositoryName string + WorkspaceName string + type InitOpts struct + Force bool + NonInteractive bool + RepositoriesDir string + Reset bool + StatusFile string + WorkspacesDir string + type ListWorktreesOpts struct + RepositoryName string + WorkspaceName string + type LoadWorktreeOpts struct + IDEName string + Remote string + RepositoryName string + type NewCodeManagerParams struct + Dependencies *dependencies.Dependencies + type OpenWorktreeOpts struct + RepositoryName string + WorkspaceName string + type RepositoryInfo struct + InRepositoriesDir bool + Name string + Path string + type WorkspaceInfo struct + Name string + Repositories []string + Worktrees []string