MWE: caption() { echo "$@" echo "$@" | sed 's/./-/g' # -> SC2001 } caption "$@" I'd like to use parameter expansion in order to get rid of the she
I'm running shellcheck on my scripts and often get this warning (which in this case is correct, because cd foo bar baz makes no sense): cd ${SOME_DIR} || exit 1