Skip to content

[Console] Add #[AsCommand] attribute to console commands - #8782

Closed
TomasVotruba wants to merge 1 commit into
mainfrom
phpstan-neon-cleanup
Closed

TomasVotruba wants to merge 1 commit into
mainfrom
phpstan-neon-cleanup

Conversation

@TomasVotruba

Copy link
Copy Markdown
Member

The symplify.commandHasAsCommandAttribute ignore was removed from phpstan.neon in 5e4c60e, but the 7 console commands still set their name via $this->setName() inside configure(), so PHPStan now reports the missing attribute.

This adds #[AsCommand(name: ...)] to each command and drops the redundant setName() call. Descriptions, aliases and options stay in configure().

@TomasVotruba
TomasVotruba deleted the phpstan-neon-cleanup branch October 23, 2026 09:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant