Use annotations and autoconfiguration

Use the `AsCommand` annotation to automatically register commands as
services and automatically add them to `./bin/console` instead of adding
them manually.
This commit is contained in:
Oliver Davies 2024-02-26 20:40:58 +00:00
parent bfc9a89842
commit 4ebfd9333a
17 changed files with 78 additions and 81 deletions

View file

@ -1,10 +0,0 @@
framework:
router:
# Configure how to generate URLs in non-HTTP contexts, such as CLI commands.
# See https://symfony.com/doc/current/routing.html#generating-urls-in-commands
#default_uri: http://localhost
when@prod:
framework:
router:
strict_requirements: null

View file

@ -1,5 +0,0 @@
controllers:
resource:
path: ../src/Controller/
namespace: App\Controller
type: attribute

View file

@ -1,4 +0,0 @@
when@dev:
_errors:
resource: '@FrameworkBundle/Resources/config/routing/errors.xml'
prefix: /_error