Re:Shef
by ajb on Tuesday March 11, 2025 @02:47AM
(#43329812)
>With just a little bit of effort, shell scripting really isn’t that arcane.
It isn't, but at least bash and posix shell don't really have scoping, structured variables, or reliable error handling (too many ways an error code can be invisibly dropped)
To get them, you need to use a
less used shell like hush or powershell. And one reason those haven't taken over, is that if you have to add a dependency you might as well use a full language anyway. But I agree that YAML isn't a good option for scripting either
Re:Shef
by bradhe on Tuesday March 11, 2025 @08:27PM
(#43338664)
Yeah exactly, Python if you need all those features for safety. If portability is more important to you, maybe it’s OK to put up with the weird quirks of bash.
It isn't, but at least bash and posix shell don't really have scoping, structured variables, or reliable error handling (too many ways an error code can be invisibly dropped)
To get them, you need to use a less used shell like hush or powershell. And one reason those haven't taken over, is that if you have to add a dependency you might as well use a full language anyway. But I agree that YAML isn't a good option for scripting either