Chapter 5: Shell Variables

76

completion is attempted after the value is changed, Bash adds the contents of the new file to the existing list. If HOSTFILE is set, but has no value, or does not name a readable file, Bash attempts to read /etc/hosts to obtain the list of possible hostname completions. When HOSTFILE is unset, the hostname list is cleared.

HOSTNAME

The name of the current host.

HOSTTYPE

A string describing the machine Bash is running on.

IGNOREEOF

Controls the action of the shell on receipt of an EOF character as the sole input.

If set, the value denotes the number of consecutive EOF characters that can be read as the first character on an input line before the shell will exit. If the variable exists but does not have a numeric value (or has no value) then the default is 10. If the variable does not exist, then EOF signifies the end of input to the shell. This is only in effect for interactive shells.

INPUTRC

The name of the Readline initialization file, overriding the default of

~/.inputrc.

LANG

Used to determine the locale category for any category not specifically selected with a variable starting with LC_.

LC_ALL

This variable overrides the value of LANG and any other LC_ variable specifying a locale category.

LC_COLLATE

This variable determines the collation order used when sorting the results of filename expansion, and determines the behavior of range expressions, equiv- alence classes, and collating sequences within filename expansion and pattern matching (see Section 3.5.8 [Filename Expansion], page 30).

LC_CTYPE

This variable determines the interpretation of characters and the behavior of character classes within filename expansion and pattern matching (see

Section 3.5.8 [Filename Expansion], page 30).

LC_MESSAGES

This variable determines the locale used to translate double-quoted strings pre- ceded by a ‘$’ (see Section 3.1.2.5 [Locale Translation], page 7).

LC_NUMERIC

This variable determines the locale category used for number formatting.

LINENO

The line number in the script or shell function currently executing.

LINES

Used by the select command to determine the column length for printing selection lists. Automatically set if the checkwinsize option is enabled (see

Section 4.3.2 [The Shopt Builtin], page 62), or in an interactive shell upon receipt of a SIGWINCH.

MACHTYPE

A string that fully describes the system type on which Bash is executing, in the standard gnu cpu-company-system format.