logger

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package Logger provides a singleton which allows consistent logging across the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get() *sypl.Sypl

Get returns logger. If logger isn't setup, it will exit with fatal.

func Setup

func Setup(o *Options) *sypl.Sypl

Setup logger. If it fails to setup, it will exit with fatal.

Types

type Options

type Options struct {
	FileLevel string `validate:"required,gte=3"`
	FilePath  string `validate:"required"`
	Level     string `validate:"required,gte=3"`
}

Options for logging .

func (*Options) Default

func (o *Options) Default()

Default options values for empty fields.

Jump to

Keyboard shortcuts

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