Store the settings in the cache.

@param string $env
@param array  $data

@return void
511930
public function store($env, array $data)
    {
        $this->files->put($this->path($env), '<?php return '.var_export($data, true).';'.PHP_EOL);
    }
647029
public function setData($data)
    {
        $resultData = $this->hydrateIfJsonToArray($data);
        if (!empty($resultData)) {
            $this->data = $resultData;
        }
        else {
            $this->data = [];
        }
    }
363013
public function setEnvProperty($name, $version)
    {
        if (! isset($this->data['env']) || ! is_array($this->data['env'])) {
            $this->data['env'] = [];
        }

        $this->data['env'][$name] = $version;
    }
741995
protected function setEnv(CommandInterface $command, array $definition)
    {
        if (isset($definition[static::CONFIG_ENV])) {
            $command->setEnv($definition[static::CONFIG_ENV]);
        }
    }
642053
public function save(array $data, $key)
    {
        $this->redis->set($this->decorateKey($key), $data);
    }
439840
protected function buildEnvironmentVariables($env)
    {
        $variables = '';
        foreach ($env as $key => $value) {
            $variables .= $key.'='.$value.' ';
        }

        return trim($variables);
    }
1314026
public function save(string $id, array $data)
    {
        $this->setFile($id);
        if ($this->file) {
            if (file_exists($this->file)) {
                $this->update($id, $data);
            } else {
                $this->add($id, $data);
            }
        }
    }
224760
private function callDelCreaServer(string $env)
    {
        Server::delete(FEnv::get("framework.compiled")."$env/", 'directory');
        Server::create(FEnv::get("framework.compiled")."$env/", 'directory');
    }
206895
function store(err, resp, data) {
  if (err && (err.code == 'EADDRINFO' || err.code == 'ENOTFOUND'))
    failed.push(data);
}
273239
def _set_env(self, env):
        
        for callback in self.callbacks:
            if callable(getattr(callback, '_set_env', None)):
                callback._set_env(env)
1256409
protected function saveDotEnvData( $data )
	{
		$dotEnvPath = base_path( '.env' );
		$dotEnv = "\n";
		foreach( $data as $key => $value ) {
			$dotEnv .= "{$key}={$value}\n";
		}
		file_put_contents( $dotEnvPath, $dotEnv );
	}
1248651
public function setEnv($env)
    {
        if (! $env) $env = self::ENV_DEVELOPMENT;

        $this->env = $env;
        $this->config('env', $this->env);
        return $this->getEnv();
    }
1166919
public function persist($data = null)
    {
        if (is_null($data)) {
            $data = $this->database->toArray();
        }

        if (! is_array($data)) {
            $data = $data->toArray();
        }

        $this->makeDir($this->getFileName());

        file_put_contents($this->getFileName(), json_encode($data));
    }
909413
protected function updateEnvironmentFile($env = null)
    {
        if ($env === null) {
            $env = $this->generateEnv();
        }

        if ($env !== null) {
            // Store the new .env file values
            if (file_put_contents($this->laravel->environmentFilePath(), $env)) {
                return true;
            }

            // Attempt to store settings in a separate file so the user doesn't have to repeat
            Storage::put('temp.env', $env);
        }

        return false;
    }
557246
public function loadConfig($file, $env = self::ENV_COMMON)
    {
        $this->loadConfigFile($file, $env, false);
    }
1333923
public static function setEnvVariables()
    {
        $env_variables = [];

        if (file_exists(static::projectRoot() . '/.env')) {
            $env_variables = (new Dotenv(static::projectRoot()))
                ->load();
        }

        self::$projectEnv = $env_variables;
    }
940172
public function setArray(array $data, bool $create = false): void
    {
        foreach ($data as $key => $value) {
            $this->set($key, $value, $create);
        }
    }