Documentation
¶
Overview ¶
Package deps provides the deps rule data ingest engine
Index ¶
Constants ¶
View Source
const ( // PullRequestIngestTypeNew is a filter that exposes only new dependencies in the pull request PullRequestIngestTypeNew = "new" // PullRequestIngestTypeNewAndUpdated is a filter that exposes new and updated // dependencies in the pull request PullRequestIngestTypeNewAndUpdated = "new_and_updated" // PullRequestIngestTypeAll is a filter that exposes all dependencies in the pull request PullRequestIngestTypeAll = "all" )
View Source
const (
// DepsRuleDataIngestType is the type of the deps rule data ingest engine
DepsRuleDataIngestType = "deps"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Deps ¶
type Deps struct {
// contains filtered or unexported fields
}
Deps is the engine for a rule type that uses deps data ingest
func NewDepsIngester ¶
func NewDepsIngester(cfg *pb.DepsType, gitprov interfaces.GitProvider) (*Deps, error)
NewDepsIngester creates a new deps rule data ingest engine
func (*Deps) GetConfig ¶
func (gi *Deps) GetConfig() protoreflect.ProtoMessage
GetConfig returns the config for the git rule data ingest engine
func (*Deps) Ingest ¶
func (gi *Deps) Ingest(ctx context.Context, ent protoreflect.ProtoMessage, params map[string]any) (*interfaces.Ingested, error)
Ingest does the actual data ingestion for a rule type by cloning a git repo, and scanning it for dependencies with a dependency extractor
type PullRequestConfig ¶ added in v0.0.79
type PullRequestConfig struct {
Filter string `json:"filter" yaml:"filter" mapstructure:"filter"`
}
PullRequestConfig is the set of parameters to the deps rule data ingest engine for pull requests
type RepoConfig ¶ added in v0.0.79
type RepoConfig struct {
Branch string `json:"branch" yaml:"branch" mapstructure:"branch"`
}
RepoConfig is the set of parameters to the deps rule data ingest engine for repositories
Click to show internal directories.
Click to hide internal directories.