Skip to content

wolframite/monolog-bunyan-formatter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bunyan Formatter for Monolog Build Status

About

The Bunyan formatter was ported from the Punyan project to support projects which already started with Monolog

Requirements

  • = PHP 5.3

  • Composer

Installation

composer require lunatic/monolog-bunyan-formatter

Usage

use Monolog\Logger;
use Monolog\Handler\StreamHandler;
use Lunatic666\Monolog\Formatter\BunyanFormatter;

$log = new Logger('demo');
$handler = new StreamHandler('php://stdout', Logger::INFO);
$handler->setFormatter(new BunyanFormatter());
$log->pushHandler($handler);

$log->info('Hello, Mr. Bunyan', array('link' => 'https://en.wikipedia.org/wiki/Paul_Bunyan'));

About

Make monolog produce bunyan style output

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages