> Clever. Would it not be easier thus: > > case "`set -o 2>/dev/null`" in > *"posix "* ) set -o posix ;; > esac
The first "" are redundant, and you can't be sure whether a space or a tab appears as the whitespace in the selection pattern. But how likely are we to have a shell that has an option that has the substring "posix", without also supporting the actual option "posix"? Why not: case `set -o 2>/dev/null` in *posix*) set -o posix ;; esac -- Eric Blake
