Skip to content

Commit

Permalink
[5.x] Remove old logic from support details command (#10360)
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonvarga authored Jun 24, 2024
1 parent 873ff37 commit a9b4746
Showing 1 changed file with 0 additions and 36 deletions.
36 changes: 0 additions & 36 deletions src/Console/Commands/SupportDetails.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,7 @@
namespace Statamic\Console\Commands;

use Illuminate\Console\Command;
use Illuminate\Foundation\Application;
use Illuminate\Foundation\Console\AboutCommand;
use Statamic\Console\RunsInPlease;
use Statamic\Facades\Addon;
use Statamic\Statamic;

class SupportDetails extends Command
{
Expand All @@ -17,38 +13,6 @@ class SupportDetails extends Command
protected $description = 'Outputs details helpful for support requests';

public function handle()
{
return class_exists(AboutCommand::class)
? $this->handleUsingAboutCommand()
: $this->handleUsingStatamic();
}

private function handleUsingStatamic()
{
$this->line(sprintf('<info>Statamic</info> %s %s', Statamic::version(), Statamic::pro() ? 'Pro' : 'Solo'));
$this->line('<info>Laravel</info> '.Application::VERSION);
$this->line('<info>PHP</info> '.phpversion());
$this->line(sprintf('<info>Stache Watcher</info> %s', config('statamic.stache.watcher') ? 'Enabled' : 'Disabled'));
$this->line(sprintf('<info>Static Caching</info> %s', config('statamic.static_caching.strategy') ?: 'Disabled'));
$this->addons();

return static::SUCCESS;
}

private function addons()
{
$addons = Addon::all();

if ($addons->isEmpty()) {
return $this->line('No addons installed');
}

foreach ($addons as $addon) {
$this->line(sprintf('<info>%s</info> %s', $addon->package(), $addon->version()));
}
}

private function handleUsingAboutCommand()
{
$this->replaceView();

Expand Down

0 comments on commit a9b4746

Please sign in to comment.