true — Return a value of 0

Format

true [argument …]

Description

true simply yields an exit status of zero (success). It ignores any arguments given on the command line. This can be surprisingly useful—for example, when you are evaluating shell expressions for their side effects.

Usage notes

true is a built-in shell command.

Localization

true uses the following localization environment variables:
  • LANG
  • LC_ALL
  • LC_MESSAGES
  • NLSPATH

See Localization for more information.

Exit values

Since true always succeeds, the only possible exit status is:
0
Successful completion

Portability

POSIX.2, X/Open Portability Guide, UNIX systems.

Related information

sh