Documentation
¶
Index ¶
- func AddWorktree(repoDir, path, branch string, createBranch bool) error
- func BranchExists(repoDir, branch string) bool
- func CheckoutRemoteBranch(repoDir, branch string) error
- func DeleteBranch(repoDir, branch string, force bool) error
- func FetchBranch(repoDir, branch string) error
- func GetCurrentBranch(dir string) (string, error)
- func GetRepoRoot(dir string) (string, error)
- func ListRemoteBranches(repoDir string) ([]string, error)
- func RemoteBranchExists(repoDir, branch string) bool
- func RemoveWorktree(repoDir, path string, force bool) error
- type Worktree
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddWorktree ¶
AddWorktree creates a new worktree
func BranchExists ¶
BranchExists checks if a branch exists
func CheckoutRemoteBranch ¶ added in v0.2.0
CheckoutRemoteBranch creates local branch tracking remote
func DeleteBranch ¶
DeleteBranch deletes a local branch
func FetchBranch ¶ added in v0.2.0
FetchBranch fetches a specific branch from origin
func GetCurrentBranch ¶
GetCurrentBranch returns the current branch name
func GetRepoRoot ¶
GetRepoRoot returns the root directory of the git repository
func ListRemoteBranches ¶ added in v0.2.0
ListRemoteBranches returns all branches on origin
func RemoteBranchExists ¶ added in v0.2.0
RemoteBranchExists checks if branch exists on origin
func RemoveWorktree ¶
RemoveWorktree removes a worktree
Types ¶
Click to show internal directories.
Click to hide internal directories.