$linuxjunkies
>

environment

also: environment variables, env

A set of variables and their values that a process inherits and uses to modify its behavior, including PATH, HOME, and USER.

The environment is a collection of name-value pairs (environment variables) maintained by the shell and passed to every command or process you run. These variables configure how programs behave without requiring command-line arguments.

Common environment variables include PATH (where the shell searches for executables), HOME (your user directory), USER (your username), and LANG (language/locale settings). You can view all variables with env or printenv.

For example, when you type ls, the shell finds it because /usr/bin is in your PATH environment variable. You can set variables permanently in shell config files like ~/.bashrc or temporarily in your current session with export MY_VAR='value'.

Related terms