Back to godoc.org
github.com/pieterclaerhout/go-james/internal

package internal

v1.6.0
Latest Go to latest
Published: May 28, 2020 | License: Apache-2.0 | Module: github.com/pieterclaerhout/go-james

Index

type Executor

type Executor struct {
	common.Logging

	Path string
}

Executor is used to execute the subcommands

func NewExecutor

func NewExecutor(path string) Executor

NewExecutor returns a new Executor instance

The path to the project is changed to the absolute path is it exists

func (Executor) RunTool

func (executor Executor) RunTool(subcommand Subcommand, parseConfig bool) int

RunTool runs the given tool

parseConfig is used to indicate if the config file should be parsed or not

type Subcommand

type Subcommand interface {
	Execute(project common.Project, cfg config.Config) error // Execute executes the subcommand with the given project and config
	RequiresBuild() bool                                     // Return true if a build is required before running the command
}

Subcommand defines the interface a subcommand need to implement

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
f or F : Jump to identifier