ui

package
v0.0.0-...-f1c34e1 Latest Latest
Warning

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

Go to latest
Published: May 1, 2024 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HasInput

func HasInput(fd uintptr, timeout time.Duration) (bool, error)

Types

type ExecUI

type ExecUI interface {
	ParsingBatchSpec()
	ParsingBatchSpecSuccess()
	ParsingBatchSpecFailure(error)

	ResolvingNamespace()
	ResolvingNamespaceSuccess(namespace string)

	PreparingContainerImages()
	PreparingContainerImagesProgress(done, total int)
	PreparingContainerImagesSuccess()

	DeterminingWorkspaceCreatorType()
	DeterminingWorkspaceCreatorTypeSuccess(wt workspace.CreatorType)

	DeterminingWorkspaces()
	DeterminingWorkspacesSuccess(workspacesCount, reposCount int, unsupported batches.UnsupportedRepoSet, ignored batches.IgnoredRepoSet)

	CheckingCache()
	CheckingCacheSuccess(cachedSpecsFound int, tasksToExecute int)

	ExecutingTasks(verbose bool, parallelism int) executor.TaskExecutionUI
	ExecutingTasksSkippingErrors(err error)

	LogFilesKept(files []string)

	NoChangesetSpecs()
	UploadingChangesetSpecs(num int)
	UploadingChangesetSpecsProgress(done, total int)
	UploadingChangesetSpecsSuccess(ids []graphql.ChangesetSpecID)

	CreatingBatchSpec()
	CreatingBatchSpecSuccess(previewURL string)
	CreatingBatchSpecError(maxUnlicensedCS int, err error) error

	PreviewBatchSpec(previewURL string)

	ApplyingBatchSpec()
	ApplyingBatchSpecSuccess(batchChangeURL string)

	ExecutionError(error)

	UploadingWorkspaceFiles()
	UploadingWorkspaceFilesWarning(error)
	UploadingWorkspaceFilesSuccess()

	DockerWatchDogWarning(error)
}

type IntervalProcessWriter

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

IntervalProcessWriter accepts stdout/stderr writes from processes, prefixed them accordingly, and flushes to the given sink on the given interval.

func NewIntervalProcessWriter

func NewIntervalProcessWriter(ctx context.Context, interval time.Duration, sink func(string)) *IntervalProcessWriter

NewIntervalProcessWriter returns a new IntervalProcessWriter instance and spawns a goroutine in the background that regularily flushed the logged output to the given sink.

If the passed in ctx is canceled the goroutine will exit.

func (*IntervalProcessWriter) Close

func (l *IntervalProcessWriter) Close() error

Close blocks until all pending writes have been flushed to the buffer. It then causes the underlying goroutine to exit.

func (*IntervalProcessWriter) StderrWriter

func (l *IntervalProcessWriter) StderrWriter() io.Writer

SterrWriter returns an io.Writer that prefixes every line with "stderr: "

func (*IntervalProcessWriter) StdoutWriter

func (l *IntervalProcessWriter) StdoutWriter() io.Writer

StdoutWriter returns an io.Writer that prefixes every line with "stdout: "

type JSONLines

type JSONLines struct {
	BinaryDiffs bool
}

func (*JSONLines) ApplyingBatchSpec

func (ui *JSONLines) ApplyingBatchSpec()

func (*JSONLines) ApplyingBatchSpecSuccess

func (ui *JSONLines) ApplyingBatchSpecSuccess(batchChangeURL string)

func (*JSONLines) CheckingCache

func (ui *JSONLines) CheckingCache()

func (*JSONLines) CheckingCacheSuccess

func (ui *JSONLines) CheckingCacheSuccess(cachedSpecsFound int, tasksToExecute int)

func (*JSONLines) CreatingBatchSpec

func (ui *JSONLines) CreatingBatchSpec()

func (*JSONLines) CreatingBatchSpecError

func (ui *JSONLines) CreatingBatchSpecError(_ int, err error) error

func (*JSONLines) CreatingBatchSpecSuccess

func (ui *JSONLines) CreatingBatchSpecSuccess(batchSpecURL string)

func (*JSONLines) DeterminingWorkspaceCreatorType

func (ui *JSONLines) DeterminingWorkspaceCreatorType()

func (*JSONLines) DeterminingWorkspaceCreatorTypeSuccess

func (ui *JSONLines) DeterminingWorkspaceCreatorTypeSuccess(wt workspace.CreatorType)

func (*JSONLines) DeterminingWorkspaces

func (ui *JSONLines) DeterminingWorkspaces()

func (*JSONLines) DeterminingWorkspacesSuccess

func (ui *JSONLines) DeterminingWorkspacesSuccess(workspacesCount, reposCount int, unsupported batches.UnsupportedRepoSet, ignored batches.IgnoredRepoSet)

func (*JSONLines) DockerWatchDogWarning

func (ui *JSONLines) DockerWatchDogWarning(err error)

func (*JSONLines) ExecutingTasks

func (ui *JSONLines) ExecutingTasks(_ bool, _ int) executor.TaskExecutionUI

func (*JSONLines) ExecutingTasksSkippingErrors

func (ui *JSONLines) ExecutingTasksSkippingErrors(err error)

func (*JSONLines) ExecutionError

func (ui *JSONLines) ExecutionError(err error)

func (*JSONLines) LogFilesKept

func (ui *JSONLines) LogFilesKept(files []string)

func (*JSONLines) NoChangesetSpecs

func (ui *JSONLines) NoChangesetSpecs()

func (*JSONLines) ParsingBatchSpec

func (ui *JSONLines) ParsingBatchSpec()

func (*JSONLines) ParsingBatchSpecFailure

func (ui *JSONLines) ParsingBatchSpecFailure(err error)

func (*JSONLines) ParsingBatchSpecSuccess

func (ui *JSONLines) ParsingBatchSpecSuccess()

func (*JSONLines) PreparingContainerImages

func (ui *JSONLines) PreparingContainerImages()

func (*JSONLines) PreparingContainerImagesProgress

func (ui *JSONLines) PreparingContainerImagesProgress(done, total int)

func (*JSONLines) PreparingContainerImagesSuccess

func (ui *JSONLines) PreparingContainerImagesSuccess()

func (*JSONLines) PreviewBatchSpec

func (ui *JSONLines) PreviewBatchSpec(batchSpecURL string)

func (*JSONLines) ResolvingNamespace

func (ui *JSONLines) ResolvingNamespace()

func (*JSONLines) ResolvingNamespaceSuccess

func (ui *JSONLines) ResolvingNamespaceSuccess(namespace string)

func (*JSONLines) UploadingChangesetSpecs

func (ui *JSONLines) UploadingChangesetSpecs(num int)

func (*JSONLines) UploadingChangesetSpecsProgress

func (ui *JSONLines) UploadingChangesetSpecsProgress(done, total int)

func (*JSONLines) UploadingChangesetSpecsSuccess

func (ui *JSONLines) UploadingChangesetSpecsSuccess(ids []graphql.ChangesetSpecID)

func (*JSONLines) UploadingWorkspaceFiles

func (ui *JSONLines) UploadingWorkspaceFiles()

func (*JSONLines) UploadingWorkspaceFilesSuccess

func (ui *JSONLines) UploadingWorkspaceFilesSuccess()

func (*JSONLines) UploadingWorkspaceFilesWarning

func (ui *JSONLines) UploadingWorkspaceFilesWarning(err error)

func (*JSONLines) WriteAfterStepResult

func (ui *JSONLines) WriteAfterStepResult(key string, value execution.AfterStepResult)

type TUI

type TUI struct {
	Out *output.Output
	// contains filtered or unexported fields
}

func (*TUI) ApplyingBatchSpec

func (ui *TUI) ApplyingBatchSpec()

func (*TUI) ApplyingBatchSpecSuccess

func (ui *TUI) ApplyingBatchSpecSuccess(batchChangeURL string)

func (*TUI) CheckingCache

func (ui *TUI) CheckingCache()

func (*TUI) CheckingCacheSuccess

func (ui *TUI) CheckingCacheSuccess(cachedSpecsFound int, uncachedTasks int)

func (*TUI) CreatingBatchSpec

func (ui *TUI) CreatingBatchSpec()

func (*TUI) CreatingBatchSpecError

func (ui *TUI) CreatingBatchSpecError(maxUnlicensedCS int, err error) error

func (*TUI) CreatingBatchSpecSuccess

func (ui *TUI) CreatingBatchSpecSuccess(previewURL string)

func (*TUI) DeterminingWorkspaceCreatorType

func (ui *TUI) DeterminingWorkspaceCreatorType()

func (*TUI) DeterminingWorkspaceCreatorTypeSuccess

func (ui *TUI) DeterminingWorkspaceCreatorTypeSuccess(wt workspace.CreatorType)

func (*TUI) DeterminingWorkspaces

func (ui *TUI) DeterminingWorkspaces()

func (*TUI) DeterminingWorkspacesSuccess

func (ui *TUI) DeterminingWorkspacesSuccess(workspacesCount, reposCount int, unsupported batches.UnsupportedRepoSet, ignored batches.IgnoredRepoSet)

func (*TUI) DockerWatchDogWarning

func (ui *TUI) DockerWatchDogWarning(err error)

func (*TUI) ExecutingBatchSpec

func (ui *TUI) ExecutingBatchSpec()

func (*TUI) ExecutingBatchSpecSuccess

func (ui *TUI) ExecutingBatchSpecSuccess()

func (*TUI) ExecutingTasks

func (ui *TUI) ExecutingTasks(verbose bool, parallelism int) executor.TaskExecutionUI

func (*TUI) ExecutingTasksSkippingErrors

func (ui *TUI) ExecutingTasksSkippingErrors(err error)

func (*TUI) ExecutionError

func (ui *TUI) ExecutionError(err error)

func (*TUI) LogFilesKept

func (ui *TUI) LogFilesKept(files []string)

func (*TUI) NoChangesetSpecs

func (ui *TUI) NoChangesetSpecs()

func (*TUI) ParsingBatchSpec

func (ui *TUI) ParsingBatchSpec()

func (*TUI) ParsingBatchSpecFailure

func (ui *TUI) ParsingBatchSpecFailure(err error)

func (*TUI) ParsingBatchSpecSuccess

func (ui *TUI) ParsingBatchSpecSuccess()

func (*TUI) PreparingContainerImages

func (ui *TUI) PreparingContainerImages()

func (*TUI) PreparingContainerImagesProgress

func (ui *TUI) PreparingContainerImagesProgress(done, total int)

func (*TUI) PreparingContainerImagesSuccess

func (ui *TUI) PreparingContainerImagesSuccess()

func (*TUI) PreviewBatchSpec

func (ui *TUI) PreviewBatchSpec(batchSpecURL string)

func (*TUI) RemoteSuccess

func (ui *TUI) RemoteSuccess(url string)

func (*TUI) ResolvingNamespace

func (ui *TUI) ResolvingNamespace()

func (*TUI) ResolvingNamespaceSuccess

func (ui *TUI) ResolvingNamespaceSuccess(_namespace string)

func (*TUI) ResolvingWorkspaces

func (ui *TUI) ResolvingWorkspaces()

func (*TUI) ResolvingWorkspacesSuccess

func (ui *TUI) ResolvingWorkspacesSuccess(workspacesCount int)

func (*TUI) SendingBatchChange

func (ui *TUI) SendingBatchChange()

func (*TUI) SendingBatchChangeSuccess

func (ui *TUI) SendingBatchChangeSuccess()

func (*TUI) SendingBatchSpec

func (ui *TUI) SendingBatchSpec()

func (*TUI) SendingBatchSpecSuccess

func (ui *TUI) SendingBatchSpecSuccess()

func (*TUI) UploadingChangesetSpecs

func (ui *TUI) UploadingChangesetSpecs(num int)

func (*TUI) UploadingChangesetSpecsProgress

func (ui *TUI) UploadingChangesetSpecsProgress(done, total int)

func (*TUI) UploadingChangesetSpecsSuccess

func (ui *TUI) UploadingChangesetSpecsSuccess(ids []graphql.ChangesetSpecID)

func (*TUI) UploadingWorkspaceFiles

func (ui *TUI) UploadingWorkspaceFiles()

func (*TUI) UploadingWorkspaceFilesSuccess

func (ui *TUI) UploadingWorkspaceFilesSuccess()

func (*TUI) UploadingWorkspaceFilesWarning

func (ui *TUI) UploadingWorkspaceFilesWarning(err error)

Jump to

Keyboard shortcuts

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