logger

package
v1.2.1-housekeeping.0 Latest Latest
Warning

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

Go to latest
Published: Aug 27, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package logger provides a wrapper for slog configuration

It looks for env variables (LOG_LEVEL, LOG_AS, LOG_TO) to determine level, type and location the logs should go to. By default, it assumed "info", "txt" and "stdout" respectively.

Call `LogSetup()` to configure the default slog logger

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Level

func Level() slog.Level

func LogSetup

func LogSetup()

LogSetup handles config for the default logger, checking env vars to determine log levels, log type (json or text) and log destination (stdout / file)

Types

This section is empty.

Jump to

Keyboard shortcuts

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