June 28, 2026
Shell yeah, now they’re arguing
POSIX Is Not a Shell
Your “portable” script may be lying, and the comments are absolutely fighting about it
TLDR: The article says the “standard shell” isn’t one actual program, so simple scripts can behave differently depending on what’s installed. Commenters immediately split between “that’s just how standards work,” “nice ad for your tool,” and “lol, your portability checker needs Docker.”
A deceptively tiny line of code launched a full-blown nerd civil war: type echo "C:\new" in one so-called standard shell setup and you get exactly that back; run it somewhere else and suddenly the \n turns into a line break. The article’s big point is simple enough for non-experts: there is no single magic "POSIX shell" app. POSIX is just a rulebook, while the actual programs people use all behave a little differently. Translation: when someone says “just write it in the standard version for portability,” they may be selling a fantasy.
And the comments? Instant split-screen drama. One camp rolled its eyes hard, saying the article is making a mountain out of a documented rule: if the standard doesn’t define a behavior, then obviously you shouldn’t depend on it. One commenter basically compared the whole thing to saying a language standard like C99 or ECMAScript “isn’t a compiler” or “isn’t a runtime” — technically true, but missing the point. The other camp was more entertained, with one person praising the post as a slick, almost suspiciously elegant pitch for the author’s own testing tools. Then came the practical grumbling: one reader bailed the second they saw Docker was required, declaring the “portability” tool not very portable itself. In other words, classic internet energy: some saw a helpful reality check, some saw pedantry, and some saw a stealth product ad in a trench coat.
Key Points
- •The article argues that POSIX is a specification, while actual shell scripts run on specific implementations such as bash, dash, ash, ksh, and yash.
- •It demonstrates shell divergence with `echo "C:\new"`, where some shells print the string literally and dash interprets `\n` as a newline.
- •The article states that POSIX leaves `echo` backslash handling implementation-defined and recommends `printf` for predictable behavior.
- •It describes shell-docs as a cross-shell reference that validates documented features across 14 shells by comparing outputs and exit codes.
- •The article defines portability as testing scripts against the actual shells and versions shipped on target systems, citing examples from Ubuntu, macOS, Alpine, and enterprise Linux distributions.