Added cachet:version command
This commit is contained in:
46
app/Console/Commands/VersionCommand.php
Normal file
46
app/Console/Commands/VersionCommand.php
Normal file
@@ -0,0 +1,46 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of Cachet.
|
||||
*
|
||||
* (c) Alt Three Services Limited
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace CachetHQ\Cachet\Console\Commands;
|
||||
|
||||
use Illuminate\Console\Command;
|
||||
|
||||
/**
|
||||
* This is the version command class.
|
||||
*
|
||||
* @author James Brooks <james@alt-three.com>
|
||||
*/
|
||||
class VersionCommand extends Command
|
||||
{
|
||||
/**
|
||||
* The console command name.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $name = 'cachet:version';
|
||||
|
||||
/**
|
||||
* The console command description.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $description = 'Display the version of Cachet';
|
||||
|
||||
/**
|
||||
* Execute the console command.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function fire()
|
||||
{
|
||||
$this->info('Cachet '.CACHET_VERSION.' is installed ⚡');
|
||||
}
|
||||
}
|
||||
@@ -15,6 +15,7 @@ use CachetHQ\Cachet\Console\Commands\BeaconCommand;
|
||||
use CachetHQ\Cachet\Console\Commands\DemoMetricPointSeederCommand;
|
||||
use CachetHQ\Cachet\Console\Commands\DemoSeederCommand;
|
||||
use CachetHQ\Cachet\Console\Commands\InstallCommand;
|
||||
use CachetHQ\Cachet\Console\Commands\VersionCommand;
|
||||
use Illuminate\Console\Scheduling\Schedule;
|
||||
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
|
||||
|
||||
@@ -37,6 +38,7 @@ class Kernel extends ConsoleKernel
|
||||
DemoMetricPointSeederCommand::class,
|
||||
DemoSeederCommand::class,
|
||||
InstallCommand::class,
|
||||
VersionCommand::class,
|
||||
];
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user