paperlined.org
apps > bash
document updated 23 days ago, on Feb 28, 2025

Bash

How does Bash determine true/false?

'if' by itself

Documentation:
Without using test, Bash only considers a program's exit status. Zero ⇒ true, non-zero ⇒ false.

For example:

test, AKA [

Test is both an standalone tool /usr/bin/test, as well as a Bash built-in. It's also known as [.
Documentation:

extended test command, AKA [[

Documentation:
(TODO)

arithmetic command, AKA ((

Documentation:
(TODO)