Skip to content

register multiple commands#98

Merged
WendellAdriel merged 2 commits intominicli:mainfrom
tmhamed:tal7aouy
Jun 13, 2023
Merged

register multiple commands#98
WendellAdriel merged 2 commits intominicli:mainfrom
tmhamed:tal7aouy

Conversation

@tmhamed
Copy link
Collaborator

@tmhamed tmhamed commented Jun 10, 2023

This is a method named registerCommands that allows to register many commands instead of one command.

 /**
     * @param array<string, callable> $commands
     * @return void
     */
    public function registerCommands(array $commands): void
    {
        foreach ($commands as $name => $callable) {
            $this->registerCommand($name, $callable);
        }
    }

Copy link
Member

@WendellAdriel WendellAdriel left a comment

Choose a reason for hiding this comment

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

Some checks are failing, but besides that, I think that's all good! 💪

@tmhamed
Copy link
Collaborator Author

tmhamed commented Jun 12, 2023

Yeah you're right i forgot to lint using pint

@erikaheidi erikaheidi requested a review from WendellAdriel June 13, 2023 06:16
@WendellAdriel WendellAdriel merged commit 07718a9 into minicli:main Jun 13, 2023
@WendellAdriel
Copy link
Member

Thanks for the contribution @tal7aouy 🔥

@tmhamed
Copy link
Collaborator Author

tmhamed commented Jun 13, 2023

Happy to contribute 💯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

3 participants