Categorygithub.com/vottunio/log
modulepackage
0.1.1
Repository: https://github.com/vottunio/log.git
Documentation: pkg.go.dev

# README

log

Go Reference Build Status Go Report Card

Vottun Log is a lightweight and flexible logging library for GoLang. It provides a simple interface for logging messages with different levels of severity. The library offers various features, including log level filtering, structured logging, and log output customization.

Installation

To use Vottun Log in your Go project, you need to have Go installed and set up. Once you have Go ready, you can install the package by running the following command:

go get github.com/vottunio/log

Usage

Here's a basic example of using Vottun Log in your Go code:

package main

import (
	"github.com/vottunio/log"
)

func main() {
	// sets log destination to the standard output. You can use a file instead.
	log.SetOutput(os.Stdout)
	// sets the log level to TRACE
	log.LogLevel = log.TRACE

	log.Debugln("This is a debug message")
	log.Infoln("This is an informational message")
	log.Warnln("This is a warning message")
	log.Errorln("This is an error message")
	log.Traceln("This is an trace message")
}

And the result is:

08:01:18.750460 DEBUG [main] This is a debug message
08:01:18.750460 INFO [main] This is an info message
08:01:18.750460 WARN [main] This is a warn message
08:01:18.750460 ERROR [main] This is an error message
08:01:18.750460 TRACE [main] This is a trace message

License

Vottun Log is licensed under the MIT License.

Visit us at https://vottun.com

# Functions

Colourize is the function that provides colours for values passed to it.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Printf calls Output to print to the standard logger.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Constants

Text Colour.
Background Colour.
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
Style.
Colour Styles.
Colour Styles.
No description provided by the author
Colour Styles.
No description provided by the author
No description provided by the author
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
No description provided by the author
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.
No description provided by the author
Colour Styles.
No description provided by the author
Colour Styles.
Colour Styles.
Colour Styles.
Colour Styles.

# Variables

Stores the log level to use.

# Type aliases

No description provided by the author