Versions in this module Expand all Collapse all v0 v0.81.3 Jun 22, 2022 v0.81.2 Jun 22, 2022 Changes in this version + var InContainer = FileExists("/.dockerenv") || FileExists("/.containerenv") + func All(actions ...func()) func() + func CropImage(bin []byte, quality, x, y, width, height int) ([]byte, error) + func DefaultBackoff(interval time.Duration) time.Duration + func Dump(list ...interface{}) string + func E(args ...interface{}) ([]interface{}, error) + func EscapeGoString(s string) string + func Exec(line string, rest ...string) (string, error) + func ExecLine(std bool, line string, rest ...string) (string, error) + func FileExists(path string) bool + func FormatCLIArgs(args []string) string + func Mkdir(path string) error + func MustToJSON(data interface{}) string + func MustToJSONBytes(data interface{}) []byte + func OutputFile(p string, data interface{}) error + func Pause() + func RandString(len int) string + func ReadString(p string) (string, error) + func Retry(ctx context.Context, s Sleeper, fn func() (stop bool, err error)) error + func S(tpl string, params ...interface{}) string + func Sleep(seconds float64) + type ErrMaxSleepCount struct + Max int + func (e *ErrMaxSleepCount) Error() string + func (e *ErrMaxSleepCount) Is(err error) bool + type IdleCounter struct + func NewIdleCounter(d time.Duration) *IdleCounter + func (de *IdleCounter) Add() + func (de *IdleCounter) Done() error + func (de *IdleCounter) Wait(ctx context.Context) + type Log func(msg ...interface{}) + func (l Log) Println(msg ...interface{}) + func MultiLogger(list ...Logger) Log + type Logger interface + Println func(...interface{}) + var LoggerQuiet Logger = Log(func(_ ...interface{}) { ... }) + type Sleeper func(context.Context) error + func BackoffSleeper(initInterval, maxInterval time.Duration, ...) Sleeper + func CountSleeper(max int) Sleeper + func EachSleepers(list ...Sleeper) Sleeper + func RaceSleepers(list ...Sleeper) Sleeper