From 670500f9844932198823c15c963e58a2ef34932d Mon Sep 17 00:00:00 2001 From: Laurent Laville Date: Sun, 4 Aug 2024 07:12:32 +0000 Subject: [PATCH] add alias on legacy command and renamed it --- .changes/unreleased/Changed-20240804-071047.yaml | 3 +++ src/Console/Command/ManifestBuild.php | 3 ++- src/Console/Command/ManifestStub.php | 3 ++- 3 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 .changes/unreleased/Changed-20240804-071047.yaml diff --git a/.changes/unreleased/Changed-20240804-071047.yaml b/.changes/unreleased/Changed-20240804-071047.yaml new file mode 100644 index 0000000..d471497 --- /dev/null +++ b/.changes/unreleased/Changed-20240804-071047.yaml @@ -0,0 +1,3 @@ +kind: Changed +body: give a chance to keep migration from v3 to v4 still working, but consider legacy commands as deprecated +time: 2024-08-04T07:10:47.946091183Z diff --git a/src/Console/Command/ManifestBuild.php b/src/Console/Command/ManifestBuild.php index 0ea2c24..66ad511 100644 --- a/src/Console/Command/ManifestBuild.php +++ b/src/Console/Command/ManifestBuild.php @@ -43,7 +43,7 @@ */ final class ManifestBuild extends Command { - public const NAME = 'manifest:build'; + public const NAME = 'build'; private const HELP = <<<'HELP' The %command.name% command will generate a manifest of your application. @@ -81,6 +81,7 @@ protected function configure(): void ]; $this->setName(self::NAME) + ->setAliases(['manifest:' . self::NAME]) // give a chance to keep migration from v3 to v4 still working (but consider it as @deprecated) ->setDescription('Creates a manifest of your software components and dependencies.') ->setDefinition( new InputDefinition( diff --git a/src/Console/Command/ManifestStub.php b/src/Console/Command/ManifestStub.php index 57199e7..e1ac93d 100644 --- a/src/Console/Command/ManifestStub.php +++ b/src/Console/Command/ManifestStub.php @@ -38,7 +38,7 @@ */ final class ManifestStub extends Command { - public const NAME = 'manifest:stub'; + public const NAME = 'stub'; private const HELP = <<<'HELP' The %command.name% command will generate a stub of your manifest application. @@ -68,6 +68,7 @@ protected function configure(): void ]; $this->setName(self::NAME) + ->setAliases(['manifest:' . self::NAME]) // give a chance to keep migration from v3 to v4 still working (but consider it as @deprecated) ->setDescription('Generates a stub for your manifest application.') ->setDefinition( new InputDefinition(