Documentation ¶
Overview ¶
Package toolbox contains various nice-to-have functions and types such as log setup, formatting and so on.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnvVarResolver ¶
func EnvVarResolver() kong.ResolverFunc
EnvVarResolver is an environment variable resolver for Kong -- ie it will default to the environment variable for the parameters. The parameters are named similarly to the parameter names but in upper case and with underscores. ie "--some-parameter-name" will use the environment variable "SOME_PARAMETER_NAME"
func GetSignalChannel ¶
GetSignalChannel returns the signal channel. This is for testing.
func SendInterrupt ¶
func SendInterrupt()
SendInterrupt sends an interrupt signal to the waiting channel
func StringByteSize ¶
StringByteSize converts a size (in bytes) to bytes, kibibytes (KiB), mebibyte (MiB), gibibyte (GiB), tebibyte (TiB), pebibyte (PiB) or exbibyte (EiB) The returned string includes the unit (nnn bytes, n.nn KiB, n.nn MiB, ...)
Types ¶
This section is empty.