cjs/log

The cjs Log package.

dev-master 2017-05-13 13:10 UTC

This package is not auto-updated.

Last update: 2024-04-19 16:40:35 UTC


README

cjs,log,cjs log,monolog

monolog

https://github.com/Seldaek/monolog

demo

$channel = 'dev'; $log = new \CjsLog\Writer( new \Monolog\Logger($channel) ); #设置日志保存文件 $logFile = sprintf("/data/logs/app/%s.%s", 'jelly', 'log'); #$log->useFiles($logFile, 'debug'); #只一个文件的方式

#设置一天一个日志文件,最大保留N天文件 $log->useDailyFiles($logFile, 5, 'debug');

#写info级别日志 $log->info("hello test");

#写debug级别日志 $log->debug("hello test");

#写warning级别日志 $log->warning("hello test");