goodsnotices/app/Console/Kernel.php
zhouchangcheng e206e87197 完善
2024-05-27 15:15:51 +08:00

30 lines
696 B
PHP
Executable File

<?php
namespace App\Console;
use App\Console\Commands\HandleNotice;
use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
class Kernel extends ConsoleKernel
{
/**
* Define the application's command schedule.
*/
protected function schedule(Schedule $schedule): void
{
$schedule->command(HandleNotice::class)->everyFiveSeconds()->withoutOverlapping();
//->appendOutputTo('crontab.log');
}
/**
* Register the commands for the application.
*/
protected function commands(): void
{
$this->load(__DIR__ . '/Commands');
require base_path('routes/console.php');
}
}