internal

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const CompressSuffix = ".gz"

CompressSuffix the suffix of compressed file.

Variables

This section is empty.

Functions

func AddSuffix2path

func AddSuffix2path(filePath, suffix string) string

AddSuffix2path add suffix to file path.

eg: "/path/to/error.log" => "/path/to/error.{suffix}.log"

func BuildGlobPattern

func BuildGlobPattern(logfile string) string

BuildGlobPattern builds a glob pattern for the given logfile. NOTE: use for testing only.

func CompressFile added in v0.2.0

func CompressFile(srcPath, dstPath string) error

CompressFile compress the src file to dst file by gzip.

func PrintErrln added in v0.2.0

func PrintErrln(pfx string, err error)

PrintErrln print error to stderr with a prefix when err is not nil.

Types

This section is empty.

Jump to

Keyboard shortcuts

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