Current Option Flags

$- expands to the current option flags.

Examples

Print option flags :

1
echo "$-"

Possible output: himBHs.

BashSupport Pro is a Bash IDE with support for $- – try it now!
© 2020–2022 Joachim Ansorg
Imprint
Privacy Policy
Legal