4 ms·
"I can use the shell" != "I can write shell scripts" Bash is really difficult to write well (if at all) and too many people don't appreciate this. Of course th
by edejong 5y ago
"I can use the shell" != "I can write shell scripts"
Bash is really difficult to write well (if at all) and too many people don't appreciate this. Of course this leads to instability in shell scripts. Offender number 1? Dockerfiles!
- nikau 5y agoThat's not a shell problem, that's due to docker not having start and end layer flags, so you end up with stupid long cmd && cmd && cmd sequences to ensure it's all in one layer
- urthor 5y agoBash truly shouldn't be used for a bunch of scripting tasks. Quite simply I don't think you should ever start using shell scripts in your code base in any capacity Eventually you're going to reach something you just don't want to do in Bash, and suddenly now you've got two scripting languages in your codebase? Don't think you want that trouble. Start with a scripting language with decent control structures on day 1 and never have to worry about refactoring.