Gio.SubprocessLauncher.prototype.getenv

function getenv(variable: String): String {
    // Gjs wrapper for g_subprocess_launcher_getenv()
}
  

Returns the value of the environment variable variable in the environment of processes launched from this launcher.

The returned string is in the GLib file name encoding. On UNIX, this means that it can be an arbitrary byte string. On Windows, it will be UTF-8.

Since 2.40

variable

the environment variable to get

Returns

the value of the environment variable, null if unset