PHP code example of accentinteractive / laravel-logcleaner

1. Go to this page and download the library: Download accentinteractive/laravel-logcleaner library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

accentinteractive / laravel-logcleaner example snippets


php artisan vendor:publish --provider="Accentinteractive\LaravelLogcleaner\LaravelLogcleanerServiceProvider" --tag="config"
 php
protected function schedule(Schedule $schedule)
{
    $schedule->command('logcleaner:run')->daily()->at('01:00');
}
 php
protected function schedule(Schedule $schedule)
{
    $schedule->command('logcleaner:run', ['--keeplines' => 5000, '--keepfiles' => 14])->daily()->at('01:00');
}