Documentation ¶
Index ¶
Constants ¶
View Source
const ( DefaultMainReferenceName plumbing.ReferenceName = "refs/heads/main" OriginName string = "origin" MainBranch RefName = "main" )
Variables ¶
This section is empty.
Functions ¶
func AnnotateCommitMessage ¶
AnnotateCommitMessage adds the gitAnnotation to the commit message.
Types ¶
type GitRepository ¶
type GitRepository interface { List(ctx context.Context, ref string, listFn ListFunc) error Commit(ctx context.Context, ref, packageName, workspaceName, revision string, resources map[string]string) error Push(ctx context.Context, ref string) error }
func OpenRepository ¶
func OpenRepository(ctx context.Context, root string, repoCfg *configv1alpha1.GitRepository, opts *Options) (GitRepository, error)
type Options ¶
type Options struct { CredentialResolver auth.CredentialResolver UserInfoProvider auth.UserInfoProvider }
type RefName ¶
type RefName string
RefName represents a relative reference name (i.e. 'main', 'drafts/bucket/v1') and supports transformation to the ReferenceName in local (cached) repository (those references are in the form 'refs/remotes/origin/...') or in the remote repository (those references are in the form 'refs/heads/...').
func (RefName) ForceFetchSpec ¶
func (RefName) RefInLocal ¶
func (b RefName) RefInLocal() plumbing.ReferenceName
func (RefName) RefInRemote ¶
func (b RefName) RefInRemote() plumbing.ReferenceName
func (RefName) TagInLocal ¶
func (b RefName) TagInLocal() plumbing.ReferenceName
Source Files ¶
Click to show internal directories.
Click to hide internal directories.