
Static checking of BASH scripts is a really good idea, to the extent it is possible. On oldster pontificating: History: - the original Unix shell was quite simple and crude - Bill Joy of Berkeley created C-Shell as an extension to the original UNIX shell. It was inspired by the C language - Stephen Bourne of Bell Labs did a powerful indiosycratic extension that was the standard shell for 7th edition Unix. - David Korn of Bell Labs extended the Bourne Shell in a number of interesting ways. ksh became available in 1983, long after BSD forked UNIX. - BASH was created dby Brian Fox for the GNU Project. Released in 1989. BASH is a re-implementation of the Korn Shell. The Korn Shell was not free software until 2000 so BASH was quite useful. Each of these shells got better for scripting. Only a few features were important for intereactive use. "History" was the main one. Part of that is improved editing of a command being entered. I think history should be built into the TTY driver so all interactive programs can benefit from it. The problem remains that these shells are all pretty bad for scripting. - So many errors are undetected or detected too late. - programming features are ideosyncratic, arcane, and unnatural. String handly, list handling, and arithmetic are each odd and awkward. For interactive use, they are too complicated. Here's a size comparison on penguin.gtalug.org (an old debian system): text data bss dec hex filename 106036 4760 11280 122076 1dcdc /bin/dash 1047220 46820 40232 1134272 114ec0 /bin/bash It's true that some of us take mastering these tools as a great challenge and feel good what what we accomplish. It would be better if easy things could be easy. Having said all that, I still write shell scripts. Carefully, and not too long. I always include set -eu (Look up what that means in BASH.)