Execute the console command.
328255
public function handle()
    {
        try {
            if ($result = User::adminExists()) {
                $this->error('Your instance is already setup.');

                return;
            }
        } catch (\Exception $e) {
            // models may not be setup, keep going
        }

        try {
            $force = $this->option('force');

            if (!file_exists('phpunit.xml')) {
                copy('phpunit.xml-dist', 'phpunit.xml');
                $this->info('Created phpunit.xml with default configuration.');
            }

            if (!file_exists('.env')) {
                copy('.env-dist', '.env');
                $this->info('Created .env file with default configuration.');
            }

            if (empty(env('APP_KEY'))) {
                if (false === $this->option('no-app-key')) {
                    $this->call('key:generate');
                } else {
                    $this->info('Skipping APP_KEY generate.');
                }
            }

            $this->info('**********************************************************************************************************************');
            $this->info('* Welcome to DreamFactory Setup.');
            $this->info('**********************************************************************************************************************');

            $this->info('Running Migrations...');
            $this->call('migrate', ['--force' => $force]);
            $this->info('Migration completed successfully.');
            $this->info('**********************************************************************************************************************');

            $this->info('**********************************************************************************************************************');
            $this->info('Running Seeder...');
            $this->call('db:seed', ['--force' => $force]);
            $this->info('All tables were seeded successfully.');
            $this->info('**********************************************************************************************************************');

            $this->info('**********************************************************************************************************************');
            $this->info('Creating the first admin user...');
            $user = false;
            while (!$user) {
                $firstName = $this->option('admin_first_name');
                $lastName = $this->option('admin_last_name');
                $email = $this->option('admin_email');
                $password = $this->option('admin_password');
                $prompt = true;
                if (!empty($email) && !empty($password)) {
                    $prompt = false;
                }

                if (empty($firstName)) {
                    $firstName = ($prompt) ? $this->ask('Enter your first name') : 'FirstName';
                }
                if (empty($lastName)) {
                    $lastName = ($prompt) ? $this->ask('Enter your last name') : 'LastName';
                }
                if (empty($email)) {
                    $email = $this->ask('Enter your email address?');
                }
                if (empty($password)) {
                    $password = $this->secret('Choose a password');
                }

                $passwordConfirm = ($prompt) ? $this->secret('Re-enter password') : $password;
                $displayName = empty($displayName) ? $firstName . ' ' . $lastName : $displayName;

                $data = [
                    'first_name'            => $firstName,
                    'last_name'             => $lastName,
                    'email'                 => $email,
                    'password'              => $password,
                    'password_confirmation' => $passwordConfirm,
                    'name'                  => $displayName
                ];

                $user = User::createFirstAdmin($data);

                if (!$user) {
                    $this->error('Failed to create user.' . print_r($data['errors'], true));
                    $this->info('Please try again...');
                }
            }
            $this->info('Successfully created first admin user.');
            $this->info('**********************************************************************************************************************');

            $this->warn('*************************************************** WARNING! *********************************************************');
            $this->warn('* Please make sure following directories and all directories under them are readable and writable by your web server ');
            $this->warn('*   -> storage/');
            $this->warn('*   -> bootstrap/cache/');
            $this->warn('* Example:');
            $this->warn('*      > sudo chown -R {www user}:{your user group} storage/ bootstrap/cache/ ');
            $this->warn('*      > sudo chmod -R 2775 storage/ bootstrap/cache/ ');
            $this->warn('**********************************************************************************************************************');
            $this->info('*********************************************** Setup Successful! ****************************************************');
            $this->info('* Setup is complete! Your instance is ready. Please launch your instance using a browser.');
            $this->info('* You can run "php artisan serve" to try out your instance without setting up a web server.');
            $this->info('**********************************************************************************************************************');
        } catch (\Exception $e) {
            $this->error($e->getMessage());
        }
    }
1352208
public function handle()
    {
      $x = $this->argument('x');
      $y = $this->argument('y');

      if(is_numeric($x) && is_numeric($y)){
        $this->info($x + $y);
      }else{
        $this->error('Enter numbers la, deyy macha apa da');
      }
    }
1328179
public function handle()
    {
        $group = $this->argument('group');
        $json = $this->option('json');

        if (is_null($group) && !$json) {
            $this->warn('You must either specify a group argument or export as --json');

            return;
        }

        if (!is_null($group) && $json) {
            $this->warn('You cannot use both group argument and --json option at the same time');

            return;
        }

        $this->manager->exportTranslations($group, $json);

        if (!is_null($group)) {
            $this->info('Done writing language files for '.(($group == '*') ? 'ALL groups' : $group.' group'));
        } elseif ($json) {
            $this->info('Done writing JSON language files for translation strings');
        }
    }
293978
public function handle()
    {
        if ($this->option('all')) {
            $this->publishCommonViews();
            $this->publishAPIRoutes();
            $this->initAPIRoutes();
            $this->publishTemplates();
            $this->publishAppBaseController();
        } elseif ($this->option('templates')) {
            $this->publishTemplates();
        } elseif ($this->option('baseController')) {
            $this->publishAppBaseController();
        } else {
            $this->publishCommonViews();
            $this->publishAPIRoutes();
            $this->initAPIRoutes();
        }
    }
326173
public function handle()
    {
        $this->abortCommandExecution();
        $this->remotePath = $this->domain . '/.env';
        $this->runScp($this->localPath, $this->remotePath, null, true);
    }
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;
    }
460577
public function handle()
    {
        $action = $this->getActionArgument(['add', 'update', 'delete']);

        foreach ($this->getCurrencyArgument() as $currency) {
            $this->$action(strtoupper($currency));
        }
    }
850465
public function handle()
	{
		$connection = $this->argument('connection') ?: $this->config->get('queue.default');
		$queue = $this->argument('queue') ?: $this->config->get('queue.connections.' . $connection  . '.queue');

		$this->info(sprintf('Clearing queue "%s" on "%s"', $queue, $connection));
		$cleared = $this->clearer->clear($connection, $queue);
		$this->info(sprintf('Cleared %d jobs', $cleared));
	}
1276575
public function fire()
    {
        $module = $this->laravel['modules']->findOrFail($this->argument('module'));

        if ($module->enabled()) {
            $module->disable();

            $this->info("Module [{$module}] disabled successful.");
        } else {
            $this->comment("Module [{$module}] has already disabled.");
        }
    }
627085
public function handle()
    {
        $this->line(static::$logo);
        $this->line(Admin::getLongVersion());

        $this->comment('');
        $this->comment('Available commands:');

        $this->listAdminCommands();
    }
607912
public function handle()
    {
        if ($this->arguments()->getOption('country', false)) {
            $this->writeln('Country specified was ' . ucfirst($this->arguments()->getOption('country')) . '.');
            $this->exitWithSuccess();
        }
        $this->writeln('Flags huh? - Run this helloworld.php flags --country="england" and see what happens!');
        $this->exitWithError();
    }
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')]
        );
    }
1044170
public function handle()
    {
        $services = $this->app->config('provider');

        if(!is_null($services)) {
            $published = false;

            foreach($services as $service) {
                $publishableItems = $this->app->make($service)->publish();

                if($this->publishItems($publishableItems)) {
                    $published = true;
                }
            }

            if($published) {
                $this->info("Package assets has been published.");
            } else {
                $this->info("Package assets already published.");
            }
        }
    }
558
public function handle()
    {
        $indexConfigurator = $this->getIndexConfigurator();

        if ($indexConfigurator && ! $this->alreadyExists($indexConfigurator)) {
            $this->call('make:index-configurator', [
                'name' => $indexConfigurator,
            ]);
        }

        $searchRule = $this->getSearchRule();

        if ($searchRule && ! $this->alreadyExists($searchRule)) {
            $this->call('make:search-rule', [
                'name' => $searchRule,
            ]);
        }

        parent::handle();
    }
1136739
public function handle()
    {

        $this->modelName = $this->formatModel($this->argument('ModelName'));

        $this->modelPath = $this->formatModelPath($this->argument('ModelName'));

        if ( ! $this->chartExists()){

            $this->error('Error, can\'t find ' .$this->modelName . ' chart');
            die();

        }


        if ( $this->removeChartFromFiles() ) {

            $this->sendSuccessMessage();

            return;

        }

        $this->error('Oops, something went wrong!');


    }
146494
public function handle()
    {
        $disk = $this->argument('disk');
        $directory = $this->option('directory') ?: '';
        $recursive = ! $this->option('non-recursive');
        $counter = 0;

        $records = Media::inDirectory($disk, $directory, $recursive)->get();

        foreach ($records as $media) {
            if (! $media->fileExists()) {
                $media->delete();
                ++$counter;
                $this->info("Pruned record for file {$media->getDiskPath()}", 'v');
            }
        }

        $this->info("Pruned {$counter} record(s).");
    }
510167
public function handle()
    {
        $oldNamespace = rtrim($this->app->getNamespace(),'\\');
        $newNamespace = ucfirst($this->input->getArgument('name'));

        $this->setAppNamespace($oldNamespace, $newNamespace);

        $this->setBootstrapNamespace($oldNamespace, $newNamespace);

        $this->setConfigNamespace($oldNamespace, $newNamespace);

        $this->setComposerNamespace($oldNamespace, $newNamespace);

        $this->composerDumpAutoload();
    }