Documentation
¶
Index ¶
- func CanonicalizePath(path string) string
- func ExpandPath(path string) string
- func GenerateWorktreePath(mainRepo, branch string) string
- func GetMainRepoFromWorktree(worktreePath string) string
- func NewestTreeModTimeContext(ctx context.Context, path string) (time.Time, error)
- func RepositoryCacheKey(identity string) string
- func SetLogFunc(fn func(format string, args ...interface{}))
- type BranchInfo
- type BranchWithCommit
- type Client
- func (c *Client) Clone(ctx context.Context, cloneURL, targetPath string) error
- func (c *Client) CloneDepthOne(ctx context.Context, source, target string, environment []string) ([]byte, error)
- func (c *Client) Combined(ctx context.Context, op Operation, dir string, args ...string) ([]byte, error)
- func (c *Client) CommitsAhead(ctx context.Context, repoDir, base, ref string) (int, error)
- func (c *Client) CreateBranch(ctx context.Context, repoDir, branch string) error
- func (c *Client) CreateWorktreeFromBranch(ctx context.Context, repoDir, branch, path string) error
- func (c *Client) CreateWorktreeFromPoint(ctx context.Context, repoDir, branch, path, startingFrom string) error
- func (c *Client) CreateWorktreeFromRemoteBranch(ctx context.Context, repoDir, remoteBranch, path string) (string, error)
- func (c *Client) DeleteBranch(ctx context.Context, repoDir, branch string, force bool) error
- func (c *Client) DeleteWorktree(ctx context.Context, repoDir, path string, force bool) error
- func (c *Client) EnsureAutomationSessionWorktree(ctx context.Context, repoDir, path, revision, authorization string, ...) (bool, error)
- func (c *Client) EnsureDetachedWorktreeAtRevision(ctx context.Context, repoDir, path, revision string) (bool, error)
- func (c *Client) EnsureDetachedWorktreeAtRevisionWithHTTPAuthorization(ctx context.Context, repoDir, path, revision, authorization string) (bool, error)
- func (c *Client) EnsureManagedClone(ctx context.Context, cloneURL, target, expectedIdentity, authorization string) (string, bool, error)
- func (c *Client) EnsurePullRequestRevision(ctx context.Context, repoDir, remote string, number int, ...) error
- func (c *Client) EnsureRepo(ctx context.Context, cloneURL, targetPath string) (bool, error)
- func (c *Client) FetchRemoteBranch(ctx context.Context, repoDir, remote, branch string) error
- func (c *Client) FetchRemotes(ctx context.Context, repoDir string) error
- func (c *Client) GetBranchInfo(ctx context.Context, dir string) (*BranchInfo, error)
- func (c *Client) GetCurrentBranch(ctx context.Context, repoDir string) (string, error)
- func (c *Client) GetDefaultBranch(ctx context.Context, repoDir string) (string, error)
- func (c *Client) GetHeadCommit(ctx context.Context, dir string) (string, error)
- func (c *Client) GetHeadCommitInfo(ctx context.Context, repoDir string) (hash string, time string)
- func (c *Client) GetRepoRoot(ctx context.Context, dir string) (string, error)
- func (c *Client) IsAncestor(ctx context.Context, repoDir, commit, base string) (bool, error)
- func (c *Client) IsWorktreeClean(ctx context.Context, path string) (bool, error)
- func (c *Client) LastCommitTime(ctx context.Context, dir string) (time.Time, error)
- func (c *Client) ListBranchesWithCommits(ctx context.Context, repoDir string) ([]BranchWithCommit, error)
- func (c *Client) ListRemoteBranches(ctx context.Context, repoDir string) ([]string, error)
- func (c *Client) ListRemotes(ctx context.Context, repoDir string) ([]string, error)
- func (c *Client) ListWorktreeStates(ctx context.Context, repoDir string) ([]WorktreeState, error)
- func (c *Client) NoOutput(ctx context.Context, op Operation, dir string, args ...string) error
- func (c *Client) ObserveLiveWorktrees(ctx context.Context, repoDir string) ([]WorktreeEntry, error)
- func (c *Client) ObserveWorktrees(ctx context.Context, repoDir string) ([]WorktreeEntry, error)
- func (c *Client) OriginHostOwnerRepo(ctx context.Context, path string) (host, ownerRepo string, err error)
- func (c *Client) Output(ctx context.Context, op Operation, dir string, args ...string) ([]byte, error)
- func (c *Client) OutputWithStdin(ctx context.Context, op Operation, dir string, stdin io.Reader, args ...string) ([]byte, error)
- func (c *Client) OutputWithTimeout(ctx context.Context, op Operation, timeout time.Duration, dir string, ...) ([]byte, error)
- func (c *Client) PruneWorktrees(ctx context.Context, repoDir string) error
- func (c *Client) RefExists(ctx context.Context, repoDir, ref string) (bool, error)
- func (c *Client) RemoteHostOwnerRepos(ctx context.Context, dir string) []string
- func (c *Client) RepositoryRoot(ctx context.Context, dir string) (string, error)
- func (c *Client) ResolveMainRepoPath(ctx context.Context, repoPath string) string
- func (c *Client) ResolvePickerRepoTarget(ctx context.Context, dir string) (repoRoot string, ok bool, err error)
- func (c *Client) ResolveRepoDir(ctx context.Context, repoDir string) (string, error)
- func (c *Client) StashCountsByBranch(ctx context.Context, repoDir string) (map[string]int, error)
- func (c *Client) SwitchBranch(ctx context.Context, repoDir, branch string) error
- func (c *Client) TreeHash(ctx context.Context, repoDir, ref string) (string, error)
- func (c *Client) TreeHashesOnHistory(ctx context.Context, repoDir, base string) (map[string]bool, error)
- func (c *Client) ValidateLocalClone(ctx context.Context, path, expectedIdentity string) (string, error)
- func (c *Client) WorktreeDirtyCount(ctx context.Context, path string) (int, error)
- type Operation
- type WorktreeEntry
- type WorktreeState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CanonicalizePath ¶ added in v0.7.0
func ExpandPath ¶
func GenerateWorktreePath ¶
func GetMainRepoFromWorktree ¶
func NewestTreeModTimeContext ¶ added in v0.12.0
func RepositoryCacheKey ¶ added in v0.12.0
func SetLogFunc ¶ added in v0.10.0
func SetLogFunc(fn func(format string, args ...interface{}))
Types ¶
type BranchInfo ¶
type BranchWithCommit ¶
func (BranchWithCommit) ToProtocol ¶
func (b BranchWithCommit) ToProtocol() protocol.Branch
type Client ¶ added in v0.12.0
type Client struct{}
func (*Client) CloneDepthOne ¶ added in v0.12.0
func (*Client) CommitsAhead ¶ added in v0.12.0
func (*Client) CreateBranch ¶ added in v0.12.0
func (*Client) CreateWorktreeFromBranch ¶ added in v0.12.0
func (*Client) CreateWorktreeFromPoint ¶ added in v0.12.0
func (*Client) CreateWorktreeFromRemoteBranch ¶ added in v0.12.0
func (*Client) DeleteBranch ¶ added in v0.12.0
func (*Client) DeleteWorktree ¶ added in v0.12.0
func (*Client) EnsureAutomationSessionWorktree ¶ added in v0.12.0
func (*Client) EnsureDetachedWorktreeAtRevision ¶ added in v0.12.0
func (*Client) EnsureDetachedWorktreeAtRevisionWithHTTPAuthorization ¶ added in v0.12.0
func (*Client) EnsureManagedClone ¶ added in v0.12.0
func (*Client) EnsurePullRequestRevision ¶ added in v0.12.0
func (*Client) EnsureRepo ¶ added in v0.12.0
func (*Client) FetchRemoteBranch ¶ added in v0.12.0
func (*Client) FetchRemotes ¶ added in v0.12.0
func (*Client) GetBranchInfo ¶ added in v0.12.0
func (*Client) GetCurrentBranch ¶ added in v0.12.0
func (*Client) GetDefaultBranch ¶ added in v0.12.0
func (*Client) GetHeadCommit ¶ added in v0.12.0
func (*Client) GetHeadCommitInfo ¶ added in v0.12.0
func (*Client) GetRepoRoot ¶ added in v0.12.0
func (*Client) IsAncestor ¶ added in v0.12.0
func (*Client) IsWorktreeClean ¶ added in v0.12.0
func (*Client) LastCommitTime ¶ added in v0.12.0
func (*Client) ListBranchesWithCommits ¶ added in v0.12.0
func (*Client) ListRemoteBranches ¶ added in v0.12.0
func (*Client) ListRemotes ¶ added in v0.12.0
func (*Client) ListWorktreeStates ¶ added in v0.12.0
func (*Client) ObserveLiveWorktrees ¶ added in v0.12.0
func (*Client) ObserveWorktrees ¶ added in v0.12.0
func (*Client) OriginHostOwnerRepo ¶ added in v0.12.0
func (*Client) OutputWithStdin ¶ added in v0.12.0
func (*Client) OutputWithTimeout ¶ added in v0.12.0
func (*Client) PruneWorktrees ¶ added in v0.12.0
func (*Client) RemoteHostOwnerRepos ¶ added in v0.12.0
func (*Client) RepositoryRoot ¶ added in v0.12.0
func (*Client) ResolveMainRepoPath ¶ added in v0.12.0
func (*Client) ResolvePickerRepoTarget ¶ added in v0.12.0
func (*Client) ResolveRepoDir ¶ added in v0.12.0
func (*Client) StashCountsByBranch ¶ added in v0.12.0
func (*Client) SwitchBranch ¶ added in v0.12.0
func (*Client) TreeHashesOnHistory ¶ added in v0.12.0
func (*Client) ValidateLocalClone ¶ added in v0.12.0
type WorktreeEntry ¶
Click to show internal directories.
Click to hide internal directories.