provider

package
v0.27.0 Latest Latest
Warning

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

Go to latest
Published: May 6, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const DefaultProviderAPIUser = "git"
View Source
const (
	GitHubApp = "GitHubApp"
)

Variables

This section is empty.

Functions

func CompareHostOfURLS added in v0.13.0

func CompareHostOfURLS(uri1, uri2 string) bool

CompareHostOfURLS compares the host of two parsed URLs and returns true if they are.

func GetPipelineRunAndBranchNameFromCancelComment added in v0.22.0

func GetPipelineRunAndBranchNameFromCancelComment(comment string) (string, string, error)

func GetPipelineRunAndBranchNameFromTestComment added in v0.22.0

func GetPipelineRunAndBranchNameFromTestComment(comment string) (string, string, error)

func GetPipelineRunFromCancelComment added in v0.15.0

func GetPipelineRunFromCancelComment(comment string) string

func GetPipelineRunFromTestComment added in v0.15.0

func GetPipelineRunFromTestComment(comment string) string

func IsCancelComment added in v0.15.0

func IsCancelComment(comment string) bool

func IsOkToTestComment

func IsOkToTestComment(comment string) bool

func IsTestRetestComment

func IsTestRetestComment(comment string) bool

func Valid

func Valid(value string, validValues []string) bool

Types

type Interface

type Interface interface {
	SetLogger(*zap.SugaredLogger)
	Validate(ctx context.Context, params *params.Run, event *info.Event) error
	Detect(*http.Request, string, *zap.SugaredLogger) (bool, bool, *zap.SugaredLogger, string, error)
	ParsePayload(context.Context, *params.Run, *http.Request, string) (*info.Event, error)
	IsAllowed(context.Context, *info.Event) (bool, error)
	IsAllowedOwnersFile(context.Context, *info.Event) (bool, error)
	CreateStatus(context.Context, *info.Event, StatusOpts) error
	GetTektonDir(context.Context, *info.Event, string, string) (string, error)      // ctx, event, path, provenance
	GetFileInsideRepo(context.Context, *info.Event, string, string) (string, error) // ctx, event, path, branch
	SetClient(context.Context, *params.Run, *info.Event, *v1alpha1.Repository, *events.EventEmitter) error
	SetPacInfo(*info.PacOpts)
	GetCommitInfo(context.Context, *info.Event) error
	GetConfig() *info.ProviderConfig
	GetFiles(context.Context, *info.Event) (changedfiles.ChangedFiles, error)
	GetTaskURI(ctx context.Context, event *info.Event, uri string) (bool, string, error)
	CreateToken(context.Context, []string, *info.Event) (string, error)
	CheckPolicyAllowing(context.Context, *info.Event, []string) (bool, string)
}

type StatusOpts

type StatusOpts struct {
	PipelineRun              *v1.PipelineRun
	PipelineRunName          string
	OriginalPipelineRunName  string
	Status                   string
	Conclusion               string
	Text                     string
	DetailsURL               string
	Summary                  string
	Title                    string
	InstanceCountForCheckRun int
}

Directories

Path Synopsis
app

Jump to

Keyboard shortcuts

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