Skip to content

Commit

Permalink
[1.x] Make commands lazy (#98)
Browse files Browse the repository at this point in the history
* Make commands lazy

* Fix console command
  • Loading branch information
timacdonald authored Mar 19, 2024
1 parent 751c852 commit 9e2bd2a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"ratchet/rfc6455": "^0.3.1",
"react/promise-timer": "^1.10",
"react/socket": "^1.14",
"symfony/console": "^6.0|^7.0",
"symfony/http-foundation": "^6.3|^7.0"
},
"require-dev": {
Expand Down
2 changes: 2 additions & 0 deletions src/Console/Commands/InstallCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@
use Illuminate\Support\Arr;
use Illuminate\Support\Facades\File;
use Illuminate\Support\Str;
use Symfony\Component\Console\Attribute\AsCommand;

use function Laravel\Prompts\confirm;

#[AsCommand(name: 'reverb:install')]
class InstallCommand extends Command
{
/**
Expand Down
2 changes: 2 additions & 0 deletions src/Servers/Reverb/Console/Commands/RestartServer.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
use Illuminate\Console\Command;
use Illuminate\Support\Facades\Cache;
use Illuminate\Support\InteractsWithTime;
use Symfony\Component\Console\Attribute\AsCommand;

#[AsCommand(name: 'reverb:restart')]
class RestartServer extends Command
{
use InteractsWithTime;
Expand Down
2 changes: 2 additions & 0 deletions src/Servers/Reverb/Console/Commands/StartServer.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,10 @@
use Laravel\Reverb\Servers\Reverb\Http\Server;
use React\EventLoop\Loop;
use React\EventLoop\LoopInterface;
use Symfony\Component\Console\Attribute\AsCommand;
use Symfony\Component\Console\Command\SignalableCommandInterface;

#[AsCommand(name: 'reverb:start')]
class StartServer extends Command implements SignalableCommandInterface
{
/**
Expand Down

0 comments on commit 9e2bd2a

Please sign in to comment.