src/Leevel/Kernel/Bootstrap/LoadOption.php
protected function setEnvVar(string $name, $value = null): void
    {
        if (is_bool($value)) {
            putenv($name.'='.($value ? '(true)' : '(false)'));
        } elseif (null === $value) {
            putenv($name.'(null)');
        } else {
            putenv($name.'='.$value);
        }

        $_ENV[$name] = $value;
        $_SERVER[$name] = $value;
    }
protected function setEnvVar(string $name, $value = null): void
    {
        if (is_bool($value)) {
            putenv($name.'='.($value ? '(true)' : '(false)'));
        } elseif (null === $value) {
            putenv($name.'(null)');
        } else {
            putenv($name.'='.$value);
        }

        $_ENV[$name] = $value;
        $_SERVER[$name] = $value;
    }
设置环境变量.

@param string           $name
@param null|bool|string $value