utils

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	KB = 1 << (10 * iota) // 1024
	MB
	GB
	TB
)

Variables

This section is empty.

Functions

func Exist

func Exist(filesPath string) bool

func FormatBytesProgress

func FormatBytesProgress(bytesCompleted, totalLength int64) string

FormatBytesProgress formats the bytes completed and total length into a string representation with the appropriate suffix.

func FormatDuration

func FormatDuration(duration time.Duration) string

FormatDuration formats a duration in a human-readable format.

Types

This section is empty.

Jump to

Keyboard shortcuts

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