Skip to content

Commit

Permalink
Simplify PHP comments
Browse files Browse the repository at this point in the history
  • Loading branch information
realodix committed Apr 22, 2024
1 parent 370650f commit fb4da70
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 51 deletions.
29 changes: 4 additions & 25 deletions artisan
Original file line number Diff line number Diff line change
Expand Up @@ -5,32 +5,11 @@ use Symfony\Component\Console\Input\ArgvInput;

define('LARAVEL_START', microtime(true));

/*
|--------------------------------------------------------------------------
| Register The Auto Loader
|--------------------------------------------------------------------------
|
| Composer provides a convenient, automatically generated class loader for
| this application. We just need to utilize it! We'll simply require it
| into the script here so we don't need to manually load our classes.
|
*/

// Register the Composer autoloader...
require __DIR__.'/vendor/autoload.php';

/*
|--------------------------------------------------------------------------
| Run The Artisan Application
|--------------------------------------------------------------------------
|
| When we run the console application, the current CLI command will be
| executed by an Artisan command and the exit code is given back to
| the caller. Once the command is handled, the script terminates.
|
*/

$app = require_once __DIR__.'/bootstrap/app.php';

$status = $app->handleCommand(new ArgvInput);
// Bootstrap Laravel and handle the command...
$status = (require_once __DIR__.'/bootstrap/app.php')
->handleCommand(new ArgvInput);

exit($status);
27 changes: 1 addition & 26 deletions routes/console.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,7 @@

use Illuminate\Foundation\Inspiring;
use Illuminate\Support\Facades\Artisan;
use Illuminate\Support\Facades\Schedule;

/*
|--------------------------------------------------------------------------
| Console Commands
|--------------------------------------------------------------------------
|
| This file is where you may define all of your Closure based console
| commands. Each Closure is bound to a command instance allowing a
| simple approach to interacting with each command's IO methods.
|
*/

Artisan::command('inspire', function () {
$this->comment(Inspiring::quote());
})->purpose('Display an inspiring quote');

/*
|--------------------------------------------------------------------------
| Console Schedule
|--------------------------------------------------------------------------
|
| Below you may define your scheduled tasks, including console commands
| or system commands. These tasks will be run automatically when due
| using Laravel's built-in "schedule:run" Artisan console command.
|
*/

Schedule::command('inspire')->hourly();
})->purpose('Display an inspiring quote')->hourly();

0 comments on commit fb4da70

Please sign in to comment.