Safe Haskell | Safe |
---|---|
Language | Haskell98 |
System.SetEnv
Documentation
setEnv :: String -> String -> IO () #
setEnv name value
sets the specified environment variable to value
.
Early versions of this function operated under the mistaken belief that setting an environment variable to the empty string on Windows removes that environment variable from the environment. For the sake of compatibility, it adopted that behavior on POSIX. In particular
setEnv name ""
has the same effect as
unsetEnv
name
If you'd like to be able to set environment variables to blank strings,
use setEnv
.
Throws IOException
if name
is the empty string or
contains an equals sign.
Since: base-4.7.0.0
unsetEnv name
removes the specified environment variable from the
environment of the current process.
Throws IOException
if name
is the empty string or
contains an equals sign.
Since: base-4.7.0.0