cli

package
v0.0.0-...-b41f85f Latest Latest
Warning

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

Go to latest
Published: May 19, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CherryPicker

type CherryPicker struct {
	*logrus.Logger
	// contains filtered or unexported fields
}

CherryPicker handles Git CLI cherry-pick operations

func NewCherryPicker

func NewCherryPicker(logger *logrus.Logger, repoURL, token, owner, repo string, prID int) *CherryPicker

NewCherryPicker creates a new CherryPicker instance

func NewCherryPickerForPlatform

func NewCherryPickerForPlatform(logger *logrus.Logger, platform Platform, token, owner, repo, baseURL string, prID int) (*CherryPicker, error)

NewCherryPickerForPlatform creates a CherryPicker instance for the specified platform

func (*CherryPicker) CherryPickCommit

func (cp *CherryPicker) CherryPickCommit(commitSHA, targetBranch string) error

CherryPickCommit performs a cherry-pick operation using Git CLI

func (*CherryPicker) CherryPickCommits

func (cp *CherryPicker) CherryPickCommits(commits []git.Commit, targetBranch string) error

CherryPickCommits performs cherry-pick operations for multiple commits using Git CLI

func (*CherryPicker) GetCherryPickBranchName

func (cp *CherryPicker) GetCherryPickBranchName(commitSHA, targetBranch string) string

GetCherryPickBranchName returns the name of the branch that was created for cherry-pick Format: cherry-pick-{PR_ID}-to-{target_branch}-{short_sha}

type Platform

type Platform string

Platform represents the Git platform type

const (
	PlatformGitHub Platform = "github"
	PlatformGitLab Platform = "gitlab"
)

Jump to

Keyboard shortcuts

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