Skip to content

Commit 0b740d5

Browse files
authoredMar 19, 2024··
[4.x] Make commands lazy (#264)
* Make commands lazy * Fix soft dependency
1 parent 919d4b4 commit 0b740d5

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed
 

‎composer.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
"illuminate/console": "^9.21|^10.0|^11.0",
1515
"illuminate/filesystem": "^9.21|^10.0|^11.0",
1616
"illuminate/support": "^9.21|^10.0|^11.0",
17-
"illuminate/validation": "^9.21|^10.0|^11.0"
17+
"illuminate/validation": "^9.21|^10.0|^11.0",
18+
"symfony/console": "^6.0|^7.0"
1819
},
1920
"require-dev": {
2021
"orchestra/testbench": "^7.35|^8.15|^9.0",

‎src/AuthCommand.php

+2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44

55
use Illuminate\Console\Command;
66
use InvalidArgumentException;
7+
use Symfony\Component\Console\Attribute\AsCommand;
78

9+
#[AsCommand(name: 'ui:auth')]
810
class AuthCommand extends Command
911
{
1012
/**

‎src/ControllersCommand.php

+2
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,10 @@
55
use Illuminate\Console\Command;
66
use Illuminate\Filesystem\Filesystem;
77
use Illuminate\Support\Str;
8+
use Symfony\Component\Console\Attribute\AsCommand;
89
use Symfony\Component\Finder\SplFileInfo;
910

11+
#[AsCommand(name: 'ui:controllers')]
1012
class ControllersCommand extends Command
1113
{
1214
/**

‎src/UiCommand.php

+2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44

55
use Illuminate\Console\Command;
66
use InvalidArgumentException;
7+
use Symfony\Component\Console\Attribute\AsCommand;
78

9+
#[AsCommand(name: 'ui')]
810
class UiCommand extends Command
911
{
1012
/**

0 commit comments

Comments
 (0)
Please sign in to comment.