helpers

package
v0.4.33 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2023 License: MIT Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CancelOnSignal

func CancelOnSignal(ctx context.Context, signal_ os.Signal, cancel func()) error

func CaptureOutput added in v0.4.25

func CaptureOutput(fn func() error) (string, error)

CaptureOutput executes a provided function and captures any data the function writes to standard output. It returns the captured output as a string and any error that occurred during execution or capturing. If multiple errors occur, only the last one will be returned.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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