printenv - Display values of environment variables

Synopsis

printenv [ -s ] [ name ]

Description

The printenv utility displays the value of the environment variable name. If no name is specified, printenv displays all of the current environment variables, one per line, in the format "name=value". By default, printenv displays job environment variables.

Options

-s
Display system environment variables.

Operands

The name is the name of an environment variable in the current environment or a system environment variable.

Exit status

  • 0 when successful
  • >0 if name is not currently defined