Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Should bash be expected to change in ways that break non-trivial amounts of existing scripts at some point in the (near/<5y) future? How much change has it gone trough in the last ten years compared to, say, python or perl?

share|improve this question

closed as not constructive by Blrfl, gnat, Mark Booth, GlenH7, ChrisF Mar 7 '13 at 21:56

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

We are unable to predict the future. – Blrfl Mar 7 '13 at 16:57
Bash has already outlived a bunch of programming languages and frameworks, and will probably outlive much more. – MrFox Mar 7 '13 at 20:27
up vote 16 down vote accepted

bash has been around since 1989, and its syntax is largely compatible with that of the much older Bourne shell, which was released in 1977. Huge swaths of core functionality in many operating systems (most Linux distros, OS X, and indeed most POSIX-compatible operating systems), and many real-world systems (make systems, automated tests, initialization scripts, etc.) depend on its functionality.

Bash isn't going anywhere, because if it did break existing scripts, it would cause huge problems. To the contrary, Bash has gone out of its way to preserve backwards compatibility with every new syntax addition.

share|improve this answer
Same can be said for most shells. – Steven Burnap Mar 7 '13 at 17:01
A lot of shells have a long history. Bash, though, is explicitly compatible with the majority of code written for a shell 36 years ago, which is an unusually long history for any software product. – nneonneo Mar 7 '13 at 17:06

The syntax of bash is unlikely to change significantly. Changes to it could have catastrophic effects across unix systems (startup scripts not working after the upgrade).

One can see that things are progressing forward with bash, and various distributions are slowly updating code to remove backwards comparability with earlier versions of bash.

If you are upgrading a system and see that bash is upgrading, it may be necessary to test those ancient scripts to make sure everything is still running correctly. It probably will, but I wouldn't want to be the one doing a "OMG Fix everything yesterday!" when something is doesn't work right after trusting that everything will.

In theory, if people followed best practices for the bash scripts, it should work, but then again, please don't take my word for it.

Perl and Python keep backwards compatibility within major version numbers. Something written for perl 5.001 (1995) still runs correctly in perl 5.16.1 (August 9, 2012). A script for perl 5 will need to run in compatibility mode with perl 6.

Python appears to follow a similar "nothing breaking within a major version". Also give Python 2 or 3 a look for python backwards compatibility between major versions.

share|improve this answer
My understanding is that the whole idea of a "compatibility mode" for Perl 5 was based on being able to run Perl 5 bytecode on a Perl 6 VM. However that dream died with the Ponie project in 2006. (Behind the scenes detail. Nicholas Clark gave TPF Grants Committee a choice of projects. We voted for him to work on improvements to Perl 5 rather than to get Ponie to the point where someone other than him could work on it. That is why Ponie died.) – btilly Mar 7 '13 at 21:13
Honestly, I haven't kept up on Perl 6 much (beyond the WTF they're actually putting superpositions in the base language?!) I'm just going with what an FAQ says (said?). – user40980 Mar 7 '13 at 21:16

Not the answer you're looking for? Browse other questions tagged or ask your own question.