src/IndraGunawan/LaravelEnvHandler/Console/EnvUpdateCommand.php
private function loadDotEnv($isExample = false)
    {
        // make sure all environment clear.
        $this->emptyEnvironment();

        // load the .env(.example) file to environment
        $postfix = $isExample ? '.example' : '';
        try {
            Dotenv::load(base_path(), self::ENV . $postfix);
        } catch (InvalidArgumentException $e) {
            // if the .env file not found then return empty array
            if (!$isExample) {
                return [];
            }
            throw $e;
        }
        return $_ENV;
    }
private function loadDotEnv($isExample = false)
    {
        // make sure all environment clear.
        $this->emptyEnvironment();

        // load the .env(.example) file to environment
        $postfix = $isExample ? '.example' : '';
        try {
            Dotenv::load(base_path(), self::ENV . $postfix);
        } catch (InvalidArgumentException $e) {
            // if the .env file not found then return empty array
            if (!$isExample) {
                return [];
            }
            throw $e;
        }
        return $_ENV;
    }
Load the .env(.example) file
@param  boolean $isExample
@return array