Execute the console command.

@return mixed
190395
public function fire()
    {
        if ($name = $this->argument('module')) {
            $module = $this->laravel['modules']->findOrFail($name);

            $this->publish($module);

            return;
        }

        foreach ($this->laravel['modules']->enabled() as $module) {
            $this->publish($module);
        }
    }
312718
public function handle()
    {
        /** @var \Illuminate\Database\Connection|CouchbaseConnection $connection */
        $connection = $this->databaseManager->connection($this->option('database'));
        if ($connection instanceof CouchbaseConnection) {
            $bucket = $connection->openBucket($this->argument('bucket'));
            $fields = $this->argument('fields');
            $whereClause = $this->option('where');
            $name = $this->argument('name');
            $bucket->manager()->createN1qlIndex(
                $name,
                $fields,
                $whereClause,
                $this->option('ignore'),
                $this->option('defer')
            );
            $field = implode(",", $fields);
            $this->info("created SECONDARY INDEX [{$name}] fields [{$field}], for [{$this->argument('bucket')}] bucket.");
            if ($whereClause !== '') {
                $this->comment("WHERE clause [{$whereClause}]");
            }
        }

        return;
    }
788981
public function handle()
    {
        $sql = $this->option('command');
        $connection = $this->databaseManager->connection($this->option('connection'));
        $rows = $this->castArray($connection->select($sql, [], true));
        $headers = array_keys(Arr::get($rows, 0, []));
        $this->table($headers, $rows);
    }
447624
public function handle()
    {
        $id = $this->argument('id');

        try {
            $user = $this->prepareUser($id);
        } catch (Exception $e) {
            $this->warn($e->getMessage());
            return 1;
        }

        echo "User name: {$user->name} (ID = {$user->id})", PHP_EOL;
        echo "Created at: {$user->created_at}", PHP_EOL;
        echo "Updated at: {$user->updated_at}", PHP_EOL;

        $this->show($user, 'role');
        $this->show($user, 'permission');

        return 0;
    }
100345
public function handle()
    {
        $this->currentRoot = trim($this->laravel->getNamespace(), '\\');

        $this->setAppDirectoryNamespace();
        $this->setBootstrapNamespaces();
        $this->setConfigNamespaces();
        $this->setComposerNamespace();
        $this->setDatabaseFactoryNamespaces();

        $this->info('Application namespace set!');

        $this->composer->dumpAutoloads();

        $this->call('optimize:clear');
    }
1286894
public function handle()
    {
        if (! $this->confirmToProceed()) {
            return;
        }

        $slug = $this->argument('slug');

        if (! empty($slug)) {
            if (! $this->packages->exists($slug)) {
                return $this->error('Package does not exist.');
            }

            if ($this->packages->isEnabled($slug)) {
                $this->seed($slug);
            } else if ($this->option('force')) {
                $this->seed($slug);
            }

            return;
        }

        if ($this->option('force')) {
            $packages = $this->packages->all();
        } else {
            $packages = $this->packages->enabled();
        }

        foreach ($packages as $package) {
            $slug = $package['slug'];

            $this->seed($slug);
        }
    }
1210741
public function handle()
    {
        $key = $this->generateRandomKey();

        if ($this->option('show')) {
            return $this->line('<comment>'.$key.'</comment>');
        }

        // Next, we will replace the application key in the environment file so it is
        // automatically setup for this developer. This key gets generated using a
        // secure random byte generator and is later base64 encoded for storage.
        if (! $this->setKeyInEnvironmentFile($key)) {
            return;
        }

        $this->laravel['config']['app.key'] = $key;

        $this->info('Application key set successfully.');
    }
920736
public function handle()
    {
        $type = $this->option('type');

        if (! is_null($type) && ! in_array($type, array('package', 'module', 'theme'))) {
            return $this->error("Invalid Packages type [$type].");
        }

        $packages = $this->getPackages($type);

        if (empty($packages)) {
            if (! is_null($type)) {
                return $this->error("Your application doesn't have any Packages of type [$type].");
            }

            return $this->error("Your application doesn't have any Packages.");
        }

        $this->displayPackages($packages);
    }
532797
public function handle()
    {
        $filePaths = $this->helper->getConfigFilesSorted();

        $seeds = [];

        foreach ($filePaths as $filePath) {
            $file = json_decode(file_get_contents($filePath), true);

            if (isset($file['seeder'])) {
                $seeds[] = $file['seeder'];
            }
        }

        foreach ($seeds as $class) {
            if (class_exists($class)) {
                if (app()->environment() == 'production') {
                    $this->call('db:seed', ['--class' => $class, '--force' => true]);
                } else {
                    $this->call('db:seed', ['--class' => $class]);
                }
            }
        }

        if (app()->environment() == 'production') {
            $this->call('db:seed', ['--force' => true]);
        } else {
            $this->call('db:seed');
        }
    }
582614
public function handle()
    {
        $app = app();
        $this->version = (int) str_replace('.', '', $app->version());

        // check if module exists
        if ($this->files->exists(app_path().'/Modules/'.studly_case($this->getNameInput()))) {
            return $this->error($this->type.' already exists!');
        }

        // Create Controller
        $this->generate('controller');

        // Create Model
        $this->generate('model');

        // Create Views folder
        $this->generate('view');

        //Flag for no translation
        if (! $this->option('no-translation')) { // Create Translations folder
            $this->generate('translation');
        }

        if ($this->version < 530) {

            // Create Routes file
            $this->generate('routes');
        } else {

            // Create WEB Routes file
            $this->generate('web');
            
            // Create API Routes file
            $this->generate('api');
        }
        
        // Create Helper file
        $this->generate('helper');



        if (! $this->option('no-migration')) {

            // without hacky studly_case function
            // foo-bar results in foo-bar and not in foo_bar
            $table = str_plural(snake_case(studly_case($this->getNameInput())));
            $this->call('make:migration', ['name' => "create_{$table}_table", '--create' => $table]);
        }

        $this->info($this->type.' created successfully.');
    }
1157806
public function handle()
    {
        $model = $this->argument('model');

        if ($this->manager->isModelExists($model)) {
            return $this->showDetail($this->manager->getModel($model));
        }

        $this->error("Model {$model} is not found");
    }
317600
public function handle()
    {
        $env = new Env(base_path('.env'));
        $key = strtoupper($this->argument('key'));
        $value = (string) $this->argument('value');
        $linebreak = (bool) $this->option('line-break');

        $result = $env->set($key, $value, $linebreak)->get($key);

        if ($result !== $value) {
            $env->rollback();

            return $this->error('Could not set the value in your .env file, reverting...');
        }

        return $this->comment("Successfully set [$key] to [$value] in your .env file.");
    }
275098
public function handle()
    {
        $clear = $this->clearTransients();
        if($clear !== 0) {
            $this->error(Helpers::getLang(get_class($this), 'error', ['count' => $clear]));
            return;
        }
        $this->info(Helpers::getLang(get_class($this), 'success', []));
        return;
    }
1094188
public function handle()
	{
		$this->mcustom($this->__directives);
		$this->mextend($this->__directory, $this->__extension);
		$this->mif();
		$this->mforeach();
		$this->mfor();
		$this->mswitch();
		$this->mwhile();
		$this->mecho();
		$this->msection();
		$this->mcode();
		$this->mcomment();
		return $this->__cached;
	}
1219047
public function handle()
    {
        if (!$this->confirmToProceed()) {
            return;
        }

        $this->migrator->setConnection($this->option('database'));
        
        $repository = modules()->location($this->option('location'));
        $paths      = $this->getMigrationPaths($repository);

        $this->migrator->setOutput($this->output)->rollback(
            $paths, ['pretend' => $this->option('pretend'), 'step' => (int)$this->option('step')]
        );
    }
1003027
public function handle()
    {
        if (!$this->confirmToProceed()) {
            return;
        }

        $this->input->setOption('force', true);
        $this->input->setOption('database', $this->connection->tenantName());

        $this->processHandle(function (Website $website) {
            $this->dropAllTables(
                $database = $this->connection->tenantName()
            );

            $this->call('tenancy:migrate', [
                '--database' => $database,
                '--website_id' => [$website->id],
                '--path' => $this->option('path'),
                '--realpath' => $this->option('realpath'),
                '--force' => 1,
            ]);

            if ($this->needsSeeding()) {
                $this->call('tenancy:db:seed', [
                    '--database' => $database,
                    '--website_id' => [$website->id],
                    '--class' => $this->option('seeder'),
                    '--force' => 1,
                ]);
            }
        });
    }
1362326
public function handle()
    {
        $this->info('Generating optimized class loader');

        $this->laravel->configure('optimizer');

        $this->composer->dumpAutoloads('--no-dev --optimize');

        if ($this->option('force') || !env('APP_DEBUG')) {
            $this->info('Compiling common classes');

            $this->compileClasses();
        } else {
            $this->call('clear-compiled');
        }
    }