environment

The ENVIRON [[associative_container?]] contains the values of the current environment. This enables an environment variable to be accessed by using the environment variable name as [[key?]] within the container:

BEGIN {
  print "Your home directory is "ENVIRON["HOME"]
}

Manipulating the container does not export the revisions to a subprocess

Note that the ENVIRON [[associative_container?]] can be changed by [[assignment?]]. However, this does not affect the environment passed on to [[subprocess?]]es that may be spawned from awk, either via the [[system?]] command or through redirection.