Appendix C. Bash Options

Table C.1. shopt Options

Option

Default

Description

-o allexport

Off

All variables that are modified or created are exported.

-o braceexapnd

On

The shell performs curly brace expansion.

cdable_vars

Off

The built-in cd command assumes that unrecognized directories are variables containing a directory path.

cdspell

Off

Spell-checks the directory component in a cd path.

checkhash

Off

Verifies that commands in the command lookup table still exist before trying a path search for the command to run.

checkwinsize

Off

Determines whether the display window has been resized after every command.

cmdhist

On

Allows multiple line history command editing.

dotglob

Off

Allows . files in a pathname expansion.

-o emacs

Off

Use emacs-style line-editing keys.

-o errexit ...

Get Linux Shell Scripting with Bash now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.