Giter VIP home page Giter VIP logo

log's Introduction

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

log's People

Contributors

vottunio avatar alexlopezt avatar ihernanv avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.