All books

Professional

Apps About Coach Log in Start reading

Computer Science · Glossary

What is Environment variable?

Definition 8.4 University Computer Science — Year 1 · Chapter 8 — The Shell

An environment variable is a pair NAME=value in the environment of a running program, a list of strings that it receives when it starts, as a copy of its parent’s exported variables. A shell variable becomes part of the environment of the programs the shell starts when it is exported; NAME=value command sets it for that one command. A C program reads it with getenv("NAME").

Read in context →