Register the command.

@param string $command
@return void
437581
protected function registerHashMakeCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Commands\HashMakeCommand($app);
        });
    }
1127112
public function fire(Command $command)
    {
        $this->command = $command;

        if ($command->option('verbose')) {
            $command->blockMessage('User', 'Creating Admin User...', 'comment');
        }

        $this->seedAdminRole();
        $this->createFirstUser();
    }
125996
protected function registerMakeListenerCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Generators\Commands\ListenerMakeCommand($app);
        });
    }
826849
protected function registerCommand()
    {
        $this->app->singleton('orchestra.commands.optimize', function ($app) {
            return new OptimizeCommand($app->make('orchestra.optimize'));
        });

        $this->commands('orchestra.commands.optimize');
    }
482987
protected function registerDatabaseRollbackCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Database\Commands\DatabaseRollbackCommand($app);
        });
    }
812896
protected function registerAddonListCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Addons\Commands\AddonListCommand($app);
        });
    }
10311
public function bind($command)
    {
        $this->command = $command;
        $this->config = $command->getApplication()->config();
        $this->init();

        return $this;
    }
91747
public function fire(Command $command)
    {
        if ($command->option('verbose')) {
            $command->blockMessage('Migrations', 'Starting the module migrations ...', 'comment');
        }

        foreach ($this->modules as $module) {
            if ($command->option('verbose')) {
                $command->call('module:migrate', ['module' => $module]);
                continue;
            }
            $command->callSilent('module:migrate', ['module' => $module]);
        }
    }
795186
public function register($name)
	{
		return $this->addCommand(new Command($name, $this->input, $this->output));
	}
1276973
public function handle(RegisterMessageCommand $command)
    {
        $message = $this->desc->registerMessage($command->type_name, $command->data_arr);

        //Потом переписать под генерацию событий самим desc объектом
        //и подписку на события
        //а пока:

        $block = $this->queryAgent->getBlock('fidback',[],[]);

        //------------------
        try{
            $inqueue  = $block->inqueue_field;
            if(!$inqueue)
            {
                $inqueue = config('fidback')['inqueue'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $inqueue = config('fidback')['inqueue'];
        }
        //------------------

        try{
            $mailto  = $block->mail_rec_field;
            if(!$mailto)
            {
                $mailto = config('fidback')['mail_rec'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $mailto = config('fidback')['mail_rec'];
        }
        //------------------
        try{
            $mailto_copy1  = $block->mail_rec_copy1_field;
            if(!$mailto_copy1)
            {
                $mailto_copy1 = config('fidback')['mail_rec_copy1'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $mailto_copy1 = config('fidback')['mail_rec_copy1'];
        }
        //------------------
        try{
            $mailto_copy2  = $block->mail_rec_copy2_field;
            if(!$mailto_copy2)
            {
                $mailto_copy2 = config('fidback')['mail_rec_copy2'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $mailto_copy2 = config('fidback')['mail_rec_copy2'];
        }
        //------------------
        try{
            $mailto_copy3  = $block->mail_rec_copy3_field;
            if(!$mailto_copy3)
            {
                $mailto_copy3 = config('fidback')['mail_rec_copy3'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $mailto_copy3 = config('fidback')['mail_rec_copy3'];
        }
        //------------------

        try{
            $username  = $block->mail_username_field;
            if(!$username)
            {
                $username = config('fidback')['mail_username'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $username = config('fidback')['mail_username'];
        }
        //------------------
        try{
            $site_name  = $block->site_name_field;
            if(!$site_name)
            {
                $site_name = config('fidback')['site_name'];
            }
        }catch(WrongBlockFieldNameException $exc){
            $site_name = config('fidback')['site_name'];
        }
        //------------------

        try
        {
            $message_id = $message->id_field;

            if($inqueue)
            {
                Mail::queue('back/mail/'.$command->template,
                    ['item'=>$message],
                    function($message) use ($username, $mailto, $mailto_copy1, $mailto_copy2, $mailto_copy3, $site_name, $message_id)
                    {
                        $message->from($username, $site_name);
                        $message->to($mailto);
                        if($mailto_copy1){
                            $message->cc($mailto_copy1);
                        }
                        if($mailto_copy2){
                            $message->cc($mailto_copy2);
                        }
                        if($mailto_copy3){
                            $message->cc($mailto_copy3);
                        }
                        $message->subject('Сообщение из сайта '.$site_name);

                        Bus::dispatch(new UpdateGroupItemCommand($message_id, ['bools'=>['mailed'=>true]]));

                    },'mailqueue');
            }else{
                Mail::send('back/mail/'.$command->template,
                    ['item'=>$message],
                    function($message) use ($username, $mailto, $mailto_copy1, $mailto_copy2, $mailto_copy3, $site_name, $message_id)
                    {
                        $message->from($username, $site_name);
                        $message->to($mailto);
                        if($mailto_copy1){
                            $message->cc($mailto_copy1);
                        }
                        if($mailto_copy2){
                            $message->cc($mailto_copy2);
                        }
                        if($mailto_copy3){
                            $message->cc($mailto_copy3);
                        }
                        $message->subject('Сообщение из сайта '.$site_name);

                        Bus::dispatch(new UpdateGroupItemCommand($message_id, ['bools'=>['mailed'=>true]]));

                    });
            }
        }catch(\Exception $Exc)
        {
            Log::info($Exc->getMessage());
        }

    }
32617
public function register(CommandInterface $command)
    {
        /*
         * Gets the name of the command
         * @var string
         */
        $name = $command->getCommand();

        /*
         * Check if the command isn't already registered
         * otherwise throw an exception
         */
        if (array_key_exists($name, $this->commands)) {
            throw new CommandException("Command with name '$name' already registered");
        }

        /*
         * Adds the command to the array
         */
        $this->commands[$name] = $command;
    }
1199305
protected function registerMakeRuleCommand($command)
     {
         $this->app->singleton($command, function ($app) {
             return new Generators\Commands\RuleMakeCommand($app);
         });
     }
346693
protected function registerDatabaseUpgradeCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Database\Commands\DatabaseUpgradeCommand($app);
        });
    }
392825
protected function registerDatabaseAgainCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Database\Commands\DatabaseAgainCommand($app);
        });
    }
457978
protected function registerAddonRemoveCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Addons\Commands\AddonRemoveCommand($app);
        });
    }
1123765
protected function registerMakePolicyCommand($command)
    {
        $this->app->singleton($command, function ($app) {
            return new Generators\Commands\PolicyMakeCommand($app);
        });
    }
152955
protected function addConsoleCommand(Command $command)
    {
        Deprecated::method(3.0, 'registerNutCommands');

        $app = $this->getContainer();
        $app['nut.commands.add']($command);
    }