logoalt Hacker News

kfajdsl11/21/20241 replyview on HN

I mean, yes, but 99% of deployments are going to be bash on some flavor of Linux.


Replies

chasil11/21/2024

No, they are not.

The Debian/Ubuntu family uses the "Debian Almquist Shell" (dash) as the system shell (#!/bin/sh) for a number of reasons. It is very much not compatible with anything fancy from bash (or korn). The bash shell is available as #!/bin/bash, but that opens the door to a new set of problems (in that POSIX mode is not enabled).

In the embedded realm, busybox also implements the Almquist shell, but it does throw simple bash "slang" back in (but not this does not include arrays).

show 1 reply