Execute the command.
486593
def _execute(self, api_command, *, timeout=None):
        """"""

        if api_command.observe:
            self._observe(api_command)
            return

        method = api_command.method
        path = api_command.path
        data = api_command.data
        parse_json = api_command.parse_json
        url = api_command.url(self._host)

        proc_timeout = self._timeout
        if timeout is not None:
            proc_timeout = timeout

        command = self._base_command(method)

        kwargs = {
            'stderr': subprocess.DEVNULL,
            'timeout': proc_timeout,
            'universal_newlines': True,
        }

        if data is not None:
            kwargs['input'] = json.dumps(data)
            command.append('-f')
            command.append('-')
            _LOGGER.debug('Executing %s %s %s: %s', self._host, method, path,
                          data)
        else:
            _LOGGER.debug('Executing %s %s %s', self._host, method, path)

        command.append(url)

        try:
            return_value = subprocess.check_output(command, **kwargs)
        except subprocess.TimeoutExpired:
            raise RequestTimeout() from None
        except subprocess.CalledProcessError as err:
            raise RequestError(
                'Error executing request: {}'.format(err)) from None

        api_command.result = _process_output(return_value, parse_json)
        return api_command.result
1260031
public function handle()
    {
        parent::handle();

        $modelGenerator = new ModelGenerator($this->commandData);
        $modelGenerator->generate();

        $this->performPostActions();
    }
716001
def execute(self, *args):
        """"""
        command, kwargs = self.parse(*args)
        return self._commands.execute(command, **kwargs)
1274894
public function handle()
    {
        $this->abortCommandExecution();
        $file = $this->argument('file');
        $this->runScp(base_path($file), $this->domain, null, true);
    }
1207885
public function handle()
    {
        $this->line('Processing...');

        //get command arguments
        $message = $this->argument('message');
        $to      = $this->argument('to');
        $attach  = $this->argument('attach');

        //init client
        $this->initClient();

        //attach data
        $this->addAttachment($attach);

        //add to
        $this->addTo($to);

        //send
        $this->send($message);

        $this->info('Message sent');
    }
744084
public function handle()
    {
        // Set locale to use
        $locale = $this->argument('locale');

        // Set CSV options
        $delimiter = $this->option('delimiter');
        $enclosure = $this->option('enclosure');

        // Get path for the CSV.
        $this->export_path = $this->option('path') ?: $this->export_path;

        // Create storage dir
        if (file_exists($this->export_path) == false) {
            mkdir($this->export_path, 0755, true);
        }

        // Process all of the locales
        foreach ($this->getGroupArgument() as $group) {
            $this->createExport($locale, $group, $delimiter, $enclosure);
        }
    }
582021
public function handle()
    {
        parent::handle();

        $viewGenerator = new ViewGenerator($this->commandData);
        $viewGenerator->generate();

        $this->performPostActions();
    }
110632
public function handle()
    {
    	if ($this->confirm('Do you want to install it?', false)) {
            Artisan::call('vendor:publish',['--tag' => 'admin_migrations']);
	    	Artisan::call('vendor:publish',['--tag' => 'admin_seeds']);
	    	Artisan::call('vendor:publish',['--tag' => 'admin_public']);
	    	Artisan::call('vendor:publish',['--tag' => 'admin_views']);
	    	exec('composer dump-autoload');
	    	Artisan::call('migrate');
	    	Artisan::call('db:seed',['--class' => 'UsersTableSeeder']);

	    	$this->displayOutput();
        }
    	

    }
878337
public function handle()
    {

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


        $path = base_path('resources/views/'. $this->folderName);

        if ( $this->removeViewFiles($path) ) {

            $this->sendViewSuccessMessage();


        } else {

            $this->error('No Such Directory');

        }

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

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

        $this->setPaths();

        if ( $this->deleteCrudFiles() ) {

            $this->sendSuccessMessage();

            return;

        }

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




    }
930399
def execute(self, command):
        '''
        
        '''
        process = Popen(command, stdout=PIPE, stderr=STDOUT, universal_newlines=True)
        while True:
            if process.poll() is not None:
                self.returncode = process.returncode  # pylint: disable=W0201
                break
            yield process.stdout.readline()
1157782
public function handle()
    {
        foreach ($this->calls as $command => $info) {
            $this->line(PHP_EOL . $info);
            $this->call($command);
        }
    }
788946
public function handle()
    {
        $command = $this->option('command');

        ob_start();
        $result = $this->executeCode(
            trim(trim($command), ';').';'
        );
        $output = ob_get_clean();

        if (empty($output) === false) {
            $this->line($output);
            $result = null;
        }

        $this->getOutput()->write('=> ');
        switch (gettype($result)) {
            case 'object':
            case 'array':
                $this->line(var_export($result, true));
                break;
            case 'string':
                $this->comment($result);
                break;
            case 'NULL':
                $this->line('');
                break;
            default:
                is_numeric($result) === true ? $this->info($result) : $this->line($result);
                break;
        }
    }
857746
public function fire()
    {
        $packageName = $this->argument('packageName');
        $version = $this->argument('version');
        $version = unserialize(base64_decode($version));
        $this->postProcess($packageName, $version);
    }
724974
public function handle()
    {
        if (!$this->confirmToProceed()) {
            return;
        }

        // Next we'll gather some of the options so that we can have the right options
        // to pass to the commands. This includes options such as which database to
        // use and the path to use for the migration. Then we'll run the command.
        $database = $this->input->getOption('database');

        $path = $this->input->getOption('path');

        $force = $this->input->getOption('force');

        // If the "step" option is specified it means we only want to rollback a small
        // number of migrations before migrating again. For example, the user might
        // only rollback and remigrate the latest four migrations instead of all.
        $step = $this->input->getOption('step') ?: 0;

        if ($step > 0) {
            $this->runRollback($database, $path, $step, $force);
        } else {
            $this->runReset($database, $path, $force);
        }

        // The refresh command is essentially just a brief aggregate of a few other of
        // the migration commands and just provides a convenient wrapper to execute
        // them in succession. We'll also see if we need to re-seed the database.
        $this->call(
            'mongolid-migrate',
            [
                '--database' => $database,
                '--path' => $path,
                '--realpath' => $this->input->getOption('realpath'),
                '--force' => $force,
            ]
        );

        if ($this->needsSeeding()) {
            $this->runSeeder($database);
        }
    }
236539
public function handle()
    {
        if (! $this->confirmToProceed()) {
            return;
        }

        $this->migrator->setConnection($this->option('database'));

        // Next, we will check to see if a path option has been defined. If it has
        // we will use the path relative to the root of this installation folder
        // so that migrations may be run for any path within the applications.
        $this->migrator->run($this->getMigrationPaths(), [
            'pretend' => $this->option('pretend'),
            'step' => $this->option('step'),
        ]);
        // Once the migrator has run we will grab the note output and send it out to
        // the console screen, since the migrator itself functions without having
        // any instances of the OutputInterface contract passed into the class.
        foreach ($this->migrator->getNotes() as $note) {
            $this->output->writeln($note);
        }
        // Finally, if the "seed" option has been given, we will re-run the database
        // seed task to re-populate the database, which is convenient when adding
        // a migration and a seed at the same time, as it is only this command.
        if ($this->option('seed')) {
            $this->call('db:seed', ['--force' => true]);
        }
    }
1172386
public function fire()
    {
        $generator = new ConsoleGenerator([
            'name' => $this->argument('name'),
            'force' => $this->option('force'),
            'command' => $this->option('command'),
            'description' => $this->option('description'),
        ]);

        $generator->run();

        $this->info('Console created successfully.');
    }
1011598
public function handle()
    {

        $command = $this->argument('function') ? $this->argument('function') : 'create';
        $param = $this->argument('params') ? $this->argument('params') : '';
        if (is_callable([$this, $command])) {
            $this->$command($param);
        } else {
            $this->error(sprintf('%s command not found', $command));
        }
    }