Documentation
¶
Index ¶
- func AddAndCommitFiles(fileNames []string, commitMessage string) (string, error)
- func BranchExists(branchName string) (bool, error)
- func CheckGitClean() error
- func CreateAndSwitchBranch(branchName string) (string, error)
- func CreateGitHubPullRequest() (string, error)
- func DeleteLocalBranch(branchName string) (string, error)
- func GetCurrentBranch() (string, error)
- func IsGitRoot() (bool, error)
- func PushChanges(remote string, branch string) (string, error)
- func SwitchToBranch(branchName string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddAndCommitFiles ¶
AddAndCommitFiles adds files to the staging area and commits them with a message. Returns the commit output for logging purposes.
func BranchExists ¶
BranchExists checks if a branch with the given name exists in the Git repository.
func CheckGitClean ¶
func CheckGitClean() error
CheckGitClean checks if the Git repository is clean (i.e., no uncommitted changes).
func CreateAndSwitchBranch ¶
CreateAndSwitchBranch creates a new branch and switches to it. Returns the command output for logging purposes.
func CreateGitHubPullRequest ¶
CreateGitHubPullRequest creates a pull request on GitHub using the GitHub CLI. Returns the output of the command for logging purposes.
func DeleteLocalBranch ¶
DeleteLocalBranch deletes a local branch with the specified name. Returns the command output for logging purposes.
func GetCurrentBranch ¶
GetCurrentBranch retrieves the name of the current branch in the Git repository.
func PushChanges ¶
PushChanges pushes the changes to the specified remote and branch. Returns the command output for logging purposes.
func SwitchToBranch ¶
SwitchToBranch switches to the specified branch in the Git repository. Returns the command output for logging purposes.
Types ¶
This section is empty.