logger

package
v0.0.0-...-cb3607a Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Home

func Home(path string) string

replaces '~' with '/home/[name]' if home == "" then it does nothing

func Parent

func Parent(path string) string

returns the parent directories of a path

Types

type Logger

type Logger struct {
	*log.Logger
	Close func() error // closes the file
}

func New

func New(out io.Writer, prefix string, flag int, path string) (*Logger, error)

Allows for logging to an io.Writer and a file easily

Jump to

Keyboard shortcuts

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