Skip to content

[Backport #1977 to 5.x] Migrate bin/openapi to Symfony Console#1982

Closed
github-actions[bot] wants to merge 1 commit into5.xfrom
backport-1977-to-5.x
Closed

[Backport #1977 to 5.x] Migrate bin/openapi to Symfony Console#1982
github-actions[bot] wants to merge 1 commit into5.xfrom
backport-1977-to-5.x

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

Automated backport of #1977 to branch 5.x.

Do not modify this pull request.

Summary

Migrate bin/openapi from a 270-line standalone script with manual argument parsing to a Symfony Console application, leveraging modern Symfony 8.0 features:

  • #[AsCommand] attribute for command metadata
  • #[MapInput] with a GenerateInput DTO for declarative input definition
  • #[Argument] / #[Option] attributes on DTO properties
  • Invokable command __invoke()
  • Replace custom ConsoleLogger with Symfony's ConsoleLogger
  • Error handling via Symfony's console handler
  • SymfonyStyle for user-facing output (defaults, bootstrap info)

All existing CLI behavior is preserved (output format, exit codes, processor management, comma-separated exclude deprecation warning).

Type of Change

  • Refactor (no functional changes)

Related Issues

Part of #1953

@github-actions
Copy link
Copy Markdown
Contributor Author

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin backport-1977-to-5.x
git worktree add --checkout .worktree/backport-1977-to-5.x backport-1977-to-5.x
cd .worktree/backport-1977-to-5.x
git reset --hard HEAD^
git cherry-pick -x ce85d8ef2d1e87db5bf31bbedc915b59c927f56f baccd77d5818712bb1666b1c568996e6be863ee7 f18eaf2e24ef1f84798834f5af7e0cdde26d5d55 d7ceb1e19bb4a0139c420cbf6457733b8fabfcd7 734d780f9efe42938b656e1b80c8ca9bf2bcaa27 644fa4d4ac6f67ce8acc33136851991e6e42ac59 c83b434ec0f075ab751555e4aeed3dfb6c24bfc6 b4f97be7ba8f4ffb5f1cc17fc431901585d7c3c2 06aebb86dc9ace17c96744b4d3b019385210149f
git push --force-with-lease

@DerManoMann DerManoMann deleted the backport-1977-to-5.x branch March 30, 2026 20:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants