src/Console/CommandTrait.php
public function addCommandGroup($groupName, $commands = [])
    {
        $group = new CommandGroup($groupName);
        foreach ($commands as $val) {
            $cmd = $this->addCommand($val);
            $group->addCommand($cmd);
        }
        $this->commandGroups[] = $group;

        return $group;
    }
public function addCommandGroup($groupName, $commands = [])
    {
        $group = new CommandGroup($groupName);
        foreach ($commands as $val) {
            $cmd = $this->addCommand($val);
            $group->addCommand($cmd);
        }
        $this->commandGroups[] = $group;

        return $group;
    }
public function addCommandGroup ( $ groupName , $ commands = [ ] ) { $ group = new CommandGroup ( $ groupName ) ; foreach ( $ commands as $ val ) { $ cmd = $ this -> addCommand ( $ val ) ; $ group -> addCommand ( $ cmd ) ; } $ this -> commandGroups [ ] = $ group ; return $ group ; }
Add a command group and register the commands automatically

@param string $groupName The group name
@param array  $commands  Command array combines indexed command names or command class assoc array.

@return CommandGroup
Add a command group and register the commands automatically