output

package
v1.9.3 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithProgress

func WithProgress(name string, fn func(), outputOptions Options)

WithProgress prints a spinner while the given function is active.

func WithProgressParallel

func WithProgressParallel(wg *sync.WaitGroup, name string, outputOptions Options, c *uint64, n uint64)

WithProgressParallel will continuously print progress to stdout until the given wait group counter goes to zero. Progress is determined by the values of `c` (number of tasks completed) and the value `n` (total number of tasks).

Types

type Options

type Options struct {
	Verbosity      Verbosity
	ShowAnimations bool
}

type Verbosity

type Verbosity int
const (
	NoOutput Verbosity = iota
	DefaultOutput
	VerboseOutput
	VeryVerboseOutput
	VeryVeryVerboseOutput
)

Jump to

Keyboard shortcuts

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