Re:Unix Shell Programming: The Next 50 Years [pdf]
by oblio on Saturday June 05, 2021 @05:08AM
(#27403447)
> Yes I agree bash could have done this. But the bash codebase is very fragile and things often break. The maintainers are very concerned about breakage.
True, but that's not a good reason for such a used application. It has been around for 40 years, I think it literally has trillions of runtime hours. It's used on billions of systems, most likely.
It's exactly the place where you'd create a super comprehensive test suite that covers <<everything>> (see SQLite) and then re-architect it to make it robust.
I wonder if it's due to lack or money or due to something else.
https://www.oilshell.org/blog/2020/07/blog-roadmap.html#the-...
It turns out that bash's "shopt" can be co-opted for this, and that's exactly what Oil does. For example, after 'shopt --set parse_paren', you can do this:
Yes I agree bash could have done this. But the bash codebase is very fragile and things often break. The maintainers are very concerned about breakage.Oil is written in a way to make breakage less likely: with principled parsing and a detailed code representation using algebraic data types. I'm surprised at how much language evolution this style has enabled. It makes me optimistic about the project's future!
Although we still tons of work to do with the C++ translation -- writing a shell is hard either way!