Skip to content

Promote Invokable Commands #1580

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Promote Invokable Commands #1580

wants to merge 1 commit into from

Conversation

yceruto
Copy link
Member

@yceruto yceruto commented Jun 2, 2025

No description provided.

@yceruto yceruto force-pushed the invokable_command branch 4 times, most recently from 659d69b to 8a8c488 Compare June 2, 2025 13:29
Copy link
Member

@stof stof left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are invokable commands documented already ?

@@ -49,7 +49,8 @@
*/
#[AsCommand(
name: 'app:add-user',
description: 'Creates users and stores them in the database'
description: 'Creates users and stores them in the database',
help: HELP,
)]
final class AddUserCommand extends Command
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should probably not extend Command here if you want to showcase the simplest usage of invokable commands.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This one is still not possible without extending from Command as we're showcasing the initialize and interact methods.

It’s the ListUsersCommand that showcases the simplest usage

@yceruto
Copy link
Member Author

yceruto commented Jun 2, 2025

Documentation is in progress symfony/symfony-docs#20932 (working currently on input doc)

@yceruto yceruto force-pushed the invokable_command branch from 8a8c488 to 125ad1e Compare June 2, 2025 13:54
@yceruto
Copy link
Member Author

yceruto commented Jun 2, 2025

We should merge this PR once the doc is complete/merged

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