Fill CircleCI environment variables.

"CIRCLECI", "CIRCLE_BUILD_NUM" must be set.

@return $this
354576
protected function fillCircleCi() : self
    {
        if (isset($this->env['CIRCLECI']) && $this->env['CIRCLECI'] && isset($this->env['CIRCLE_BUILD_NUM'])) {
            $this->env['CI_BUILD_NUMBER'] = $this->env['CIRCLE_BUILD_NUM'];
            $this->env['CI_NAME'] = 'circleci';

            // backup
            $this->readEnv['CIRCLECI'] = $this->env['CIRCLECI'];
            $this->readEnv['CIRCLE_BUILD_NUM'] = $this->env['CIRCLE_BUILD_NUM'];
            $this->readEnv['CI_NAME'] = $this->env['CI_NAME'];

            $this->readEnv['CI_PR_REPO_OWNER'] = $this->env['CIRCLE_PR_USERNAME'] ?? null;
            $this->readEnv['CI_PR_REPO_NAME'] = $this->env['CIRCLE_PR_REPONAME'] ?? null;

            $this->readEnv['CI_REPO_OWNER'] = $this->env['CIRCLE_PROJECT_USERNAME'] ?? null;
            $this->readEnv['CI_REPO_NAME'] = $this->env['CIRCLE_PROJECT_REPONAME'] ?? null;

            $this->readEnv['CI_PR_NUMBER'] = $this->env['CIRCLE_PR_NUMBER'] ?? null;

            $this->readEnv['CI_BRANCH'] = $this->env['CIRCLE_BRANCH'] ?? null;
        }

        return $this;
    }
1361080
public function repopulate()
	{
		$fields = $this->field(null, true);
		foreach ($fields as $f)
		{
			// Don't repopulate the CSRF field
			if ($f->name === \Config::get('security.csrf_token_key', 'fuel_csrf_token'))
			{
				continue;
			}

			if (($value = $f->input()) !== null)
			{
				$f->set_value($value, true);
			}
		}

		return $this;
	}
728468
private function fillRunQueue()
    {
        $opts = $this->options;
        while (\count($this->pending) && \count($this->running) < $opts->processes) {
            $tokenData = $this->getNextAvailableToken();
            if ($tokenData !== false) {
                $this->acquireToken($tokenData['token']);
                $env = ['TEST_TOKEN' => $tokenData['token'], 'UNIQUE_TEST_TOKEN' => $tokenData['unique']] + Habitat::getAll();
                $this->running[$tokenData['token']] = array_shift($this->pending)->run($opts->phpunit, $opts->filtered, $env, $opts->passthru, $opts->passthruPhp);
                if ($opts->verbose) {
                    $cmd = $this->running[$tokenData['token']];
                    echo "\nExecuting test via: {$cmd->getLastCommand()}\n";
                }
            }
        }
    }
1094194
public function init()
    {
        $this->message = Swift_Message::newInstance(
            null,
            null,
            Config::get('content_type'),
            Config::get('charset')
        )
            ->setFrom(Config::get('addr'), Config::get('name'));

        return $this;
    }
645706
private function setEnvironment()
    {
        $this->sandbox = config('pagseguro.sandbox', env('PAGSEGURO_SANDBOX', true));
        $this->email = config('pagseguro.email', env('PAGSEGURO_EMAIL', ''));
        $this->token = config('pagseguro.token', env('PAGSEGURO_TOKEN', ''));
        $this->notificationURL = config('pagseguro.notificationURL', env('PAGSEGURO_NOTIFICATION', ''));
    }
539707
public function initialize()
    {
        if (! $this->app instanceof Container) {
            throw new SandboxException('A base app has not been set.');
        }

        $this->setInitialConfig();
        $this->setInitialProviders();
        $this->setInitialResetters();

        return $this;
    }
772059
protected function configureIO()
	{
		if ($this->consoleInput->hasParameterOption(['--ansi'], true))
		{
			$this->consoleOutput->setDecorated(true);
		}
		elseif ($this->consoleInput->hasParameterOption(['--no-ansi'], true))
		{
			$this->consoleOutput->setDecorated(false);
		}

		if ($this->consoleInput->hasParameterOption(['--no-interaction', '-n'], true))
		{
			$this->consoleInput->setInteractive(false);
		}

		if ($this->consoleInput->hasParameterOption(['--quiet', '-q'], true))
		{
			$this->consoleOutput->setVerbosity(OutputInterface::VERBOSITY_QUIET);
			$this->consoleInput->setInteractive(false);
		}
		else
		{
			if ($this->consoleInput->hasParameterOption('-vvv', true)
				|| $this->consoleInput->hasParameterOption('--verbose=3', true)
				|| $this->consoleInput->getParameterOption('--verbose', false, true) === 3
			)
			{
				$this->consoleOutput->setVerbosity(OutputInterface::VERBOSITY_DEBUG);
			}
			elseif ($this->consoleInput->hasParameterOption('-vv', true)
				|| $this->consoleInput->hasParameterOption('--verbose=2', true)
				|| $this->consoleInput->getParameterOption('--verbose', false, true) === 2
			)
			{
				$this->consoleOutput->setVerbosity(OutputInterface::VERBOSITY_VERY_VERBOSE);
			}
			elseif ($this->consoleInput->hasParameterOption('-v', true)
				|| $this->consoleInput->hasParameterOption('--verbose=1', true)
				|| $this->consoleInput->hasParameterOption('--verbose', true)
				|| $this->consoleInput->getParameterOption('--verbose', false, true)
			)
			{
				$this->consoleOutput->setVerbosity(OutputInterface::VERBOSITY_VERBOSE);
			}
		}
	}
707193
public function phpProboCi()
    {
        $this->executeCommandHook(__FUNCTION__, 'before');
        $this->getProjectInstance()
            ->setupProboCi();
        $this->executeCommandHook(__FUNCTION__, 'after');

        return $this;
    }
1032003
public function FromEnvironment() {
      $this->WithURI()
         ->WithArgs(self::INPUT_GET, self::INPUT_POST, self::INPUT_SERVER, self::INPUT_FILES, self::INPUT_COOKIES);
         
      return $this;
   }
681128
public function construct()
	{
		if ($this->arguments->getOpt(4))
		{
				$extension = $this->arguments->getOpt(4);
				$this->addReplacement('plugin_name', $extension);
				$this->addReplacement('extension', $extension);
		}
		else
		{
			$this->output->error("Error: must specify a hubtype.");
		}

		// Determine our base path
		$base       = $this->arguments->getOpt('app') ? PATH_APP : PATH_CORE;
		$installDir = trim($this->arguments->getOpt('install-dir'));
		if ($installDir && strlen($installDir) > 0)
		{
			if (substr($installDir, 0, 1) == DS)
			{
				$base = rtrim($installDir, DS);
			}
			else
			{
				$base .= DS . trim($installDir, DS);
			}
		}

		// Install directory is migrations folder within base
		$installDir = $base . DS . 'plugins' . DS . 'search';

		// Editor
		$editor = null;
		if ($this->arguments->getOpt('editor'))
		{
			$editor = $this->arguments->getOpt('editor');
		}
		else
		{
			$editor = (getenv('EDITOR')) ? getenv('EDITOR') : 'vi';
		}

		// @TODO detect previous file, warn about override

		// Make plugin file
		$classname   = 'plgSearch' . ucfirst($extension);
		$destination = $installDir . DS . $extension . DS .  $extension. '.php';

		// Make directory
		if (!is_dir($installDir. DS . $extension))
		{
			App::get('filesystem')->makeDirectory($installDir . DS . $extension);
		}

		$this->addTemplateFile("{$this->getType()}.tmpl", $destination)
			 ->addReplacement('class_name', $classname)
			 ->make();
	}
877666
private function getBackground()
    {
        return (new Circle($this->getX(), $this->getY(), $this->getRadius()))
            ->setFillColor($this->getBackgroundColor())
            ->setStrokeWidth(0);
    }
747640
public function set()
    {
        try {
            $this->loadEnv();
            $this->setPhpIni(getenv('WP_ENV') ?: 'development');
            $this->setConfig(getenv('WP_ENV') ?: 'development');
            $this->registerMuLoaderLoader();
            $this->registerMultiSitePath();
        } catch (\RuntimeException $e) {
            die('<h1>Configuration could not be loaded.</h1>');
        }
        return $this;
    }
114411
protected function fillAppVeyor() : self
    {
        if (isset($this->env['APPVEYOR']) && $this->env['APPVEYOR'] && isset($this->env['APPVEYOR_BUILD_NUMBER'])) {
            $this->readEnv['CI_BUILD_NUMBER'] = $this->env['APPVEYOR_BUILD_NUMBER'];
            $this->readEnv['CI_JOB_ID'] = $this->env['APPVEYOR_JOB_NUMBER'];
            $this->readEnv['CI_BRANCH'] = $this->env['APPVEYOR_REPO_BRANCH'];
            $this->readEnv['CI_PR_NUMBER'] = $this->env['APPVEYOR_PULL_REQUEST_NUMBER'] ?? '';
            $this->env['CI_NAME'] = 'AppVeyor';

            // backup
            $this->readEnv['APPVEYOR'] = $this->env['APPVEYOR'];
            $this->readEnv['APPVEYOR_BUILD_NUMBER'] = $this->env['APPVEYOR_BUILD_NUMBER'];
            $this->readEnv['APPVEYOR_JOB_NUMBER'] = $this->env['APPVEYOR_JOB_NUMBER'];
            $this->readEnv['APPVEYOR_REPO_BRANCH'] = $this->env['APPVEYOR_REPO_BRANCH'];
            $this->readEnv['CI_NAME'] = $this->env['CI_NAME'];

            $repo_slug = (string) $this->env['APPVEYOR_REPO_NAME'] ?? '';

            if ($repo_slug) {
                $slug_parts = explode('/', $repo_slug);

                $this->readEnv['CI_REPO_OWNER'] = $slug_parts[0];
                $this->readEnv['CI_REPO_NAME'] = $slug_parts[1];
            }

            $pr_slug = (string) ($this->env['APPVEYOR_PULL_REQUEST_HEAD_REPO_NAME'] ?? '');

            if ($pr_slug) {
                $slug_parts = explode('/', $pr_slug);

                $this->readEnv['CI_PR_REPO_OWNER'] = $slug_parts[0];
                $this->readEnv['CI_PR_REPO_NAME'] = $slug_parts[1];
            }

            $this->readEnv['CI_BRANCH'] = $this->env['APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH']
                ?? $this->env['APPVEYOR_REPO_BRANCH'];
        }

        return $this;
    }
239876
public function buildScopes()
	{
		$this->setScopeMapper(new ScopeMapper);
		$this->configureScopes($this->getScopeMapper());

		$this->setScopeBuilder(new FilterBuilder($this->getScopeMapper()));
		$this->getScopeBuilder()
			->build();

		return $this;
	}
232285
protected function initializeOtherValues(): ConsoleInputInterface
    {
        $this->domainName = "";
        $this->actionName = "";
        $this->options = [];
        $this->params = [];

        $this->shortOptionsValued=[];
        $this->shortOptionsVoid=[];
        $this->longOptionsValued=[];
        $this->longOptionsVoid=[];

        return $this;
    }
1183776
public function build(): SetIgnoreInputEventsRequest
	{
		$instance = new SetIgnoreInputEventsRequest();
		if ($this->ignore === null) {
			throw new BuilderException('Property [ignore] is required.');
		}
		$instance->ignore = $this->ignore;
		return $instance;
	}
1350068
protected function configureEvents(): self
    {
        $container = $this->getContainer();
        $key = 'm6web_daemon.iterations_events';

        if ($container->hasParameter($key)) {
            $this->iterationsEvents = $container->getParameter($key);
        }

        return $this;
    }