Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Human ¶
Human writes a clean, colored, human-readable summary of the result to w. Pass NewStyler(false) for plain output.
func IsTerminal ¶
IsTerminal reports whether f refers to a character device (a terminal).
func NewProgressPrinter ¶
func NewProgressPrinter(w io.Writer, animate bool) speedtest.ProgressFunc
NewProgressPrinter returns a ProgressFunc that renders a live, single-line spinner + auto-scaling bar + throughput to w. When animate is false it produces no output. The bar scales to the peak Mbps seen so far in the current phase; a phase change finalizes the previous line with a newline.
func ShouldColor ¶
ShouldColor reports whether colored/animated output should be used. noColorEnv is the raw value of the NO_COLOR environment variable; per the NO_COLOR convention, any non-empty value disables color.