contributors

package
v0.18.1 Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2026 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Overview

Package contributors reports the git contributors for a repository and the associated entity under test to the Contributors ingest API.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Emitter

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

Emitter synchronously collects and reports contributors for a given repository.

func New

func New(httpClient *http.Client, config configuration.Configuration, logger *zerolog.Logger) (*Emitter, error)

New returns an Emitter that reports contributors of a repository, sending requests over httpClient to the API configured in config.

func (*Emitter) Emit

func (e *Emitter) Emit(ctx context.Context, repoPath string, orgID uuid.UUID, item Item) error

Emit reports the repository's current contributors against item.

It returns nil when there is no git repository or no commits in the contributor window.

type Item

type Item struct {
	EntityType contributors_ingest.EntityType
	EntityID   string
}

Item identifies the entity that contributors are attributed to.

Jump to

Keyboard shortcuts

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