Project

yarl

0.0
No commit activity in last 3 years
No release in over 3 years
Yet Another Ruby Logger (YARL) extends ruby/logger to provide header colors and a severity level below DEBUG. The default formatting has been changed to provide a cleaner (subjective) look.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 2.0

Runtime

~> 1.3
 Project Readme

YARL - Yet Another Ruby Logger

YARL is a ruby/logger extension that provides:

  • Full ANSI 4-bit color support
  • SPAM -- a severity level lower than DEBUG
  • Clean, low-clutter formatting
  • Common defaults, like writing to STDOUT

As an extension, logger is fully implemented.

Color Support

YARL supports 4-bit ANSI colors -- both text and background -- in the logger header.

[citation needed]

Additionally, the following severity levels have message colors:

  • FATAL has a background color -- defaults to red
  • ERROR has a text color -- defaults to red
  • SPAM has a text color -- defaults to bright black

Levels and their colors

Installation

Add this line to your application's Gemfile:

gem 'yarl'

And then execute:

$ bundle

Or install it yourself as:

$ gem install yarl

Usage

Simple Example

require 'yarl'

logger = YARL.new "Simple Example", color: :green
logger.info "Hello, World!"

will produce A simple example

Complex Example

Please see examples/complex.rb for the source code.

This example will produce A complex example

Contributing

Feel free to make an issue, and I will do my best to respond quickly.

Or, fork it, edit it, and pull request.