Package Data | |
---|---|
Maintainer Username: | Josrom |
Maintainer Contact: | jvortsromero@gmail.com (Jose Vicente) |
Package Create Date: | 2017-07-20 |
Package Last Update: | 2018-04-09 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2024-11-16 15:01:17 |
Package Statistics | |
---|---|
Total Downloads: | 3,094 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 0 |
Total Watchers: | 2 |
Total Forks: | 0 |
Total Open Issues: | 0 |
ChannelLog provides a feature to log in different files.
To get the last version of ChannelLog, simply require the project using Composer:
composer require josrom/laravel-logger
Instead, you may of course manually update your require block and run composer update if you so choose:
{
"require": {
"josrom/laravel-logger": "0.1.*"
}
}
Add the service provider and alias to config/app.php
file:
'providers' => [
// Other Service Providers
Laravel\ChannelLog\ChannelLogServiceProvider::class,
],
'aliases' => [
// Other Alias
'ChannelLog' => \Laravel\ChannelLog\ChannelLog::class,
],
After to set up the provider, copy the default config file from the package using the vendor:publish
artisan command:
php artisan vendor:publish --provider="Laravel\ChannelLog\ChannelLogServiceProvider"
Edit the config to add new logs, channels and extras:
'error' => [
'path' => 'logs/laravel-error.log',
'level' => \Monolog\Logger::ERROR,
],
'info' => [
'path' => 'logs/laravel-info.log',
'level' => \Monolog\Logger::INFO,
'extras' => ['internet-provider'],
],
internet-provider