processors

package
v0.0.0-...-993d511 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2019 License: AGPL-3.0 Imports: 33 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Factory

type Factory interface {
	BuildProcessor(ctx context.Context, t *task.PRAnalysis) (Processor, error)
}

func NewGithubFactory

func NewGithubFactory() Factory

type GithubGoRepo

type GithubGoRepo struct {
	GithubGoRepoConfig
	// contains filtered or unexported fields
}

func NewGithubGoRepo

func NewGithubGoRepo(ctx context.Context, cfg GithubGoRepoConfig, analysisGUID, repoName, branch string) (*GithubGoRepo, error)

func (GithubGoRepo) Process

func (g GithubGoRepo) Process(ctx context.Context) error

type GithubGoRepoConfig

type GithubGoRepoConfig struct {
	// contains filtered or unexported fields
}

type IgnoredError

type IgnoredError struct {
	Status        github.Status
	StatusDesc    string
	IsRecoverable bool
}

func (IgnoredError) Error

func (e IgnoredError) Error() string

type JSONDuration

type JSONDuration time.Duration

func (JSONDuration) MarshalJSON

func (d JSONDuration) MarshalJSON() ([]byte, error)

func (JSONDuration) String

func (d JSONDuration) String() string

type NopProcessor

type NopProcessor struct{}

func (NopProcessor) Process

func (p NopProcessor) Process(ctx context.Context) error

type Processor

type Processor interface {
	Process(ctx context.Context) error
}

type Repo

type Repo struct {
	RepoConfig
}

func NewRepo

func NewRepo(cfg *RepoConfig) *Repo

func (Repo) Process

func (r Repo) Process(ctx *RepoContext)

type RepoContext

type RepoContext struct {
	Ctx context.Context

	AnalysisGUID string
	Branch       string
	Repo         *github.Repo // TODO: abstract from repo provider
}

type RepoProcessorFactory

type RepoProcessorFactory struct {
	// contains filtered or unexported fields
}

func NewRepoProcessorFactory

func NewRepoProcessorFactory(cfg *StaticRepoConfig, noCtxLog logutil.Log) *RepoProcessorFactory

func (RepoProcessorFactory) BuildProcessor

func (f RepoProcessorFactory) BuildProcessor(ctx *RepoContext) (*Repo, func(), error)

type StaticRepoConfig

type StaticRepoConfig struct {
	RepoFetcher fetchers.Fetcher
	Linters     []linters.Linter
	Runner      linters.Runner
	State       repostate.Storage
	Cfg         config.Config
	Et          apperrors.Tracker
}

type Timing

type Timing struct {
	Name     string
	Duration JSONDuration `json:"DurationMs"`
}

type Warning

type Warning struct {
	Tag  string
	Text string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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