service

package
v1.3.2 Latest Latest
Warning

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

Go to latest
Published: May 27, 2025 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Contextual

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

func (*Contextual) ClientFromContext

func (ctx *Contextual) ClientFromContext(c *context.Context) (*github.Client, error)

ClientFromContext returns a client if one exists on the context

func (*Contextual) CreateContext

func (ctx *Contextual) CreateContext(c *context.Context) (context.Context, context.CancelFunc)

CreateContext creates a known context from a parent context (c)

func (*Contextual) GetClient

func (ctx *Contextual) GetClient() *github.Client

GetClient returns the client, if it exists

type Store

type Store interface {
	// WithClient applies a client to the store
	WithClient(client *github.Client) Store
	// WithConfig applies a config to to the store
	WithConfig(config *model.Config) Store
	// GetContextual returns the context wrapper associated with this store
	GetContextual() *Contextual
	// Process queries the store and converts commits to a ChangeItem before sending to the channel
	Process(parentContext *context.Context, wg *sync.WaitGroup, ciChan chan *model.ChangeItem, from string, to string) error
}

Store defines the functional interface for accessing a store of Git commits

func NewGitHubService

func NewGitHubService() Store

NewGitHubService creates a new Store for accessing commits from the GitHub API

func NewLocalGitService

func NewLocalGitService() Store

Jump to

Keyboard shortcuts

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