this post was submitted on 29 Jan 2026
22 points (95.8% liked)
Linux
61653 readers
900 users here now
From Wikipedia, the free encyclopedia
Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).
Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.
Rules
- Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
- No misinformation
- No NSFW content
- No hate speech, bigotry, etc
Related Communities
Community icon by Alpár-Etele Méder, licensed under CC BY 3.0
founded 6 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I do write my scripts in POSIX sh, more for compatibility sake. But shells like dash, mksh, are not made for interactive use, they lack most not-really-convenience features.
But heavy, that's only invocation time; it mathers more if you do things like 100 awk calls (that one is heavy to invoke) per line you parse.
Though i did write my own cross-shell session scripts, centering on the ENV variable which most shells understand (and a /etc/bash/bashrc loading it, since Bash doesn't).
Again, more because i think, why load xkb maps 3 times in 3 scripts if you can do it only once? And most session scripts look like they were never touched the last 20 years. And then a if you do it, do it right mindset.
Worth learning; i think so. You learn, with time, more about how to use shorthands and functions, to structure your scripts nicely, instead of doing if if if messes more "convenient" shells lead you to. Which benefits you in real programming languages too and leads to more readable and better maintainable scripts.
And the only times i miss convenience features like arrays is in 500+ loc scripts which would have better been done in python. Btw, don't do 500+ loc shell scripts: they do become a maintenance mess even if you do everything right.
Edit: right, i forgot the POSIXLY_CORRECT env variable. Some AUR setup-scripts have issues with a forced POSIX shell.