Skip to content

Laravel log tool based monolog. Easy log to The specified Filename which separated by date. PHP Laravel框架的日志工具,基于monolog,分文件分日期打印日志

Notifications You must be signed in to change notification settings

jasperchou/dailyfilelog

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

说明

该Log主要实现分文件按日输出日志,便于调试查错,目的是主要用于业务日志。

注册

AppServiceProvider注册
$this->app->singleton('fileLog', 'App\Utils\Log\FileDailyWriter');

使用

use App\Utils\Log\Facades\FileLog as Log;
//支持直接文件名打印
//输出在 storage/logs/filename-2018-08-10.log
//$msg可以是多种类型
Log::filename($msg);
//支持定义log级别
Log::filename('debug', $msg);
//支持常规log,各种级别的日志,会输出到到默认日志
Log::debug($msg);

About

Laravel log tool based monolog. Easy log to The specified Filename which separated by date. PHP Laravel框架的日志工具,基于monolog,分文件分日期打印日志

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages