Name
shopt — Manage shell options.
Synopsis
shopt [-opqsu] [option
]
Set or unset shell options. With no options or just
-p
, print the names and settings of the options. See
the section Shell Options, for a description of the
various options.
Options
-o
Each option must be one of the shell option names for
set
-o
, instead of the options listed in Shell Options.-p
Print the option settings as shopt commands that can be reread later.
-q
Quiet mode. The exit status is zero if the given option is set, nonzero otherwise. With multiple options, all of them must be set for a zero exit status.
-s
Set the given options. With no options, print only those that are set.
-u
Unset the given options. With no options, print only those that are unset.
Get bash Pocket Reference 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.