PRIMARY CATEGORY → SHELL SCRIPTING Globbing IFS Bash Versioning $ nvim foo.bash #!/usr/bin/env bash bash() { case $( /bin/ps -p "$PPID" -o comm= ) in *bash) return 0 ;; *) printf "Shell is not a Bash. Exiting...\n" 1>&2 return 1 ;; esac } bash || exit 99 $ chmod u+x foo.bash $ dash -c './foo.bash' Shell is not Bash. Exiting...