Next: , Previous: , Up: The language   [Contents][Index]


5.34 Environment Variables

These functions are exported by the rep.system module.

Function: getenv variable-name

This function returns the value (a string) of the environment variable called variable-name. If the specified variable doesn’t exist false is returned.

(getenv "OSTYPE")
    ⇒ "Linux"
Function: setenv variable-name new-value

This function sets the value of the environment variable called variable-name to new-value. new-value can either be a string containing the new contents of the variable or false, in which case the environment variable is deleted.

Function: unsetenv variable-name

Deletes any variable in process-environment named variable-name.

See also Process Objects for the description of the process-environment variable.