diff --git a/SC2213.md b/SC2213.md index 3f148fe..9ef44bf 100644 --- a/SC2213.md +++ b/SC2213.md @@ -36,7 +36,7 @@ Either add a case to handle the flag, or remove it from the `getopts` option str ShellCheck may not correctly recognize less canonical uses of `while getopts ..; do case ..;`, such as when modifying the variable before using it: -``` +```sh while getopts "rf-:" OPT; do if [ "$OPT" = "-" ]; then # long option: reformulate OPT and OPTARG OPT="${OPTARG%%=*}" # extract long option name