application

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2024 License: MIT Imports: 1 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Config           Config
	TargetScriptList domain.TargetScriptList
	Parser           domain.EventParser
	ScriptValidator  TargetScriptListValidator
	EventValidator   ParsedEventValidator
	Logger           Logger
}

func New

func New(config *Config, parser domain.EventParser, scriptValidator TargetScriptListValidator, eventValidator ParsedEventValidator, logger Logger) *App

func (*App) IsValid

func (a *App) IsValid(event domain.ParsedEvent) bool

func (*App) LoadTargetScriptList

func (a *App) LoadTargetScriptList(event domain.ParsedEvent) error

func (*App) LoadTargetScripts

func (a *App) LoadTargetScripts(event domain.ParsedEvent) error

func (*App) ParseEvent

func (a *App) ParseEvent() (domain.ParsedEvent, error)

func (*App) Run

func (a *App) Run(invoker ShellInvoker) error

func (*App) ValidateTargetScripts

func (a *App) ValidateTargetScripts() bool

type Config

type Config struct {
	RequiredLabel       string
	BaseBranch          string
	TargetScriptListDir string
}

type Logger

type Logger interface {
	Debug(string, ...any)
	Info(string, ...any)
	Error(string, ...any)
}

type ParsedEventValidator

type ParsedEventValidator interface {
	Validate(event domain.ParsedEvent) bool
}

type ShellInvoker

type ShellInvoker interface {
	Execute(domain.TargetScriptList) error
}

type TargetScriptListValidator

type TargetScriptListValidator interface {
	Validate(list domain.TargetScriptList) bool
}

Directories

Path Synopsis
Package application is a generated GoMock package.
Package application is a generated GoMock package.

Jump to

Keyboard shortcuts

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