ENV(3) ENV(3) NAME env - environment device SYNOPSIS bind #e /env /env/name DESCRIPTION The environment device serves a one-level directory giving access to environment variables and their values. It is conventionally bound to /env. The value of an environment variable name may be obtained by reading the file /env/name. If the file does not exist, the variable is unset and has the value nil. The maximum length of a variable name is 127 bytes. New environment variables are set by creating the corre- sponding file in /env and writing the required value to that file. Similarly environment variables are destroyed (unset) by removing the corresponding file. Processes sharing an `environment group' see the same files and contents; changes made by one process are seen by the others. A process can insulate itself from further changes using the `FORKENV' option to sys-pctl(2), which creates a new environment group that is a copy of the old, but further changes in each are independent. A new empty environment group is created by the `NEWENV' option to sys-pctl(2). SOURCE /os/port/devenv.c /emu/port/devenv.c SEE ALSO env(1), sh(1), env(2), sys-pctl(2) Page 1 Plan 9 (printed 11/22/24)