utils

package
v0.8.5 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractFile added in v0.7.0

func ExtractFile(urlStr string) (string, error)

ExtractFile extracts the file name from a URL string from an index backup.

func GetDirectorySize added in v0.7.0

func GetDirectorySize(path string) (uint64, error)

GetDirectorySize calculates the total size of a directory and returns it as a human-readable string

func GetSizeHuman added in v0.7.0

func GetSizeHuman(size uint64) string

func NormalizeString

func NormalizeString(s string) string

NormalizeString normalizes a string by converting it to lowercase and replacing spaces and underscores with hyphens.

func ParseDate added in v0.7.0

func ParseDate(date string) string

ParseDate parses a date string in RFC3339 format and returns a formatted string.

func Unzip added in v0.7.0

func Unzip(src, dest string) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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