Skip to content

Commit

Permalink
feature #1355 Create empty-ready construct on command generate (Krist…
Browse files Browse the repository at this point in the history
…ijan Stipić)

This PR was merged into the 1.0-dev branch.

Discussion
----------

Create empty-ready construct on command generate

I understand that this was not put on purpose, but I believe that it would be useful for most people, because when generating a lot of commands, in 99% of cases I have to manually write this generic code to be able to do dependency injection

Commits
-------

ec9ad72 Create empty-ready construct on command generate
  • Loading branch information
weaverryan committed Sep 7, 2023
2 parents 79c710b + ec9ad72 commit 67e0e9f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/Resources/skeleton/command/Command.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@
)]
class <?= $class_name; ?> extends Command
{
public function __construct()
{
parent::__construct();
}

protected function configure(): void
{
$this
Expand Down

0 comments on commit 67e0e9f

Please sign in to comment.