Execute the job.
553383
public function handle()
    {
        $work = $this->work;
        $data = $this->data;

        $generator = new Generators\TextGenerator();

        $callback = function ($resource, array $data) use ($work, $generator) {
            $data = array_merge($this->data, $data);
            $data = array_merge($data, (array) Yaml::parse($generator->generateAndRender($work->data, $data)));

            $payload = json_decode(json_encode(Yaml::parse($generator->generateAndRender($work->payload, $data))));

            $worker = new $payload->class();
            $worker->execute($work, $payload, $data);
        };

        if ($work->data_builder) {
            $query = $work->data_builder->newInstanceQuery((array) $this->data);

            $work->data_builder->extract($query->get(), $callback);
        } else {
            $callback(null, []);
        }
    }
126294
public function handle()
    {
        $this->identifier = self::normalize($this->argument('identifier'));

        $this->askImageUploads();
        $this->askFileUploads();
        $this->askMigration();
        $this->askActions();

        $this->compiler = new ResourceCompiler($this, $this->identifier, $this->resourceOptions);

        $this->createResource('config');
        $this->createResource('model');
        $this->createResource('request');
        $this->createResource('controller');

        if ($this->resourceOptions['migration']) {
            $this->createResource('migration');
        }
    }
568135
public function handle()
    {
        if (! $this->confirmToProceed()) {
            return;
        }

        $this->prepareDatabase();

        // 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->setOutput($this->output)
                ->run($this->getMigrationPaths(), [
                    'pretend' => $this->option('pretend'),
                    'step' => $this->option('step'),
                ]);

        // 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->option('pretend')) {
            $this->call('db:seed', ['--force' => true]);
        }
    }
1274563
public function handle()
    {
        $this->output->writeln('<info>Migrating application and plugins...</info>');

        UpdateManager::instance()
            ->setNotesOutput($this->output)
            ->update()
        ;
    }
388486
public function handle()
    {
        $file = $this->getFileName();
        $path = $this->getPath();
        $filePath = $this->getFilePath();
        $eol = PHP_EOL;

        $this->generator->makeGitIgnore($file, $path);

        if (file_exists($this->getFilePath())) {
            $this->error(PHP_EOL . 'Wordpress is already down.' . PHP_EOL);
        } else {
            $this->generator->makeMaintenanceFile($filePath);
            $this->info("{$eol}Wordpress set to maintenance mode. Either run \"artisan wp:up\" to {$eol} bring the site back up or manually delete {$eol} {$filePath}.");
        }
    }
32956
public function handle()
    {
        $this->prepareDatabase();

        $repository = modules()->location($this->option('location'));

        $this->migrate($repository);
    }
909400
public function handle()
    {
        $arguments = $this->getArgumentsWithDriver('name');
        $driver = $arguments['driver'];
        $name = $arguments['name'];

        // It's possible for the developer to specify the tables to modify in this
        // schema operation. The developer may also specify if this table needs
        // to be freshly created so we can create the appropriate migrations.
        $create = $this->input->getOption('create');
        $table = $this->input->getOption('table');

        if (! $table && \is_string($create)) {
            $table = $create;
        }

        // Now we are ready to write the migration out to disk. Once we've written
        // the migration out, we will dump-autoload for the entire framework to
        // make sure that the migrations are registered by the class loaders.
        $this->writeMigration($driver, $name, $table, $create);

        $this->composer->dumpAutoloads();
    }
627085
public function handle()
    {
        $this->line(static::$logo);
        $this->line(Admin::getLongVersion());

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

        $this->listAdminCommands();
    }
435026
public function handle()
    {
        if ($this->checkIfCanIncrement('current')) {
            $number = app('pragmarx.version')->incrementMajor();

            $this->info("New major version: {$number}");

            $this->displayAppVersion();
        }
    }
1182808
public function execute() {
		$this->out(__d('cake_ldap', 'Synchronization with LDAP server in progress...'), 1, Shell::NORMAL);
		if ($this->QueuedTask->createJob('SyncEmployee', null, null, 'sync')) {
			$this->out(__d('cake_ldap', 'Synchronization with LDAP server set in queue successfully.'), 1, Shell::NORMAL);
		} else {
			$this->out('<error>' . __d('cake_ldap', 'Synchronization with LDAP server set in queue unsuccessfully.') . '</error>');
		}
	}
1363653
public function handle()
    {
        if ($name = $this->argument('module')) {
            $module = $this->laravel['modules']->findOrFail($name);

            $this->publish($module);

            return;
        }

        foreach ($this->laravel['modules']->allEnabled() as $module) {
            $this->publish($module);
        }
    }
1288968
public function handle(): void
    {
        $this->initCommands();

        foreach ($this->calls as $info) {
            if (! isset($info['command'])) {
                continue;
            }

            $params = (isset($info['params'])) ? $info['params'] : [];

            $this->line(PHP_EOL.$info['description']);

            switch ($info['type']) {
                case 'artisan':
                    $this->call($info['command'], $params);
                    break;
                case 'cli':
                    $process = new Process($info['command']);
                    $process->run();
                    break;
            }
        }
    }
696729
public function handle()
    {
        $theme = strtolower($this->argument('name'));

        $this->installTheme($theme);
        $this->setupTheme($theme);

        if ($this->option('default')) {
            $this->setAsDefaultTheme($theme);
        }

        $this->info('Theme ['.$theme.'] installed.');
    }
173061
public function handle()
    {
        $daemon = $this->option('daemon');

        if ($this->downForMaintenance() && ! $daemon) {
            return;
        }

        // We'll listen to the processed and failed events so we can write information
        // to the console as jobs are processed, which will let the developer watch
        // which jobs are coming through a queue and be informed on its progress.

        $this->listenForEvents();

        // Get the Config Repository instance.
        $config = $this->container['config'];

        $connection = $this->argument('connection') ?: $config->get('queue.default');

        $delay = $this->option('delay');

        // The memory limit is the amount of memory we will allow the script to occupy
        // before killing it and letting a process manager restart it for us, which
        // is to protect us against any memory leaks that will be in the scripts.

        $memory = $this->option('memory');

        // We need to get the right queue for the connection which is set in the queue
        // configuration file for the application. We will pull it based on the set
        // connection being run for the queue operation currently being executed.

        $queue = $this->option('queue') ?: $config->get(
            "queue.connections.{$connection}.queue", 'default'
        );

        $this->runWorker($connection, $queue, $delay, $memory, $daemon);
    }
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);
        }
    }
1106986
public function fire()
    {
        if ($this->input->getOption('now')) {
            app()->make('liana')->setUp();
            $this->info('Liana build successfull!');
            app('log')->info('Liana build successfull!');
            return;
        }

        Queue::push('GibbonCms\Liana\Jobs\Build');

        $this->info('Queued for build...');
    }
338130
public function handle()
    {
        $this->repository->setSource($this->option('database'));

        $this->repository->createRepository();

        $this->info('Mapping table created successfully');
    }