Today I learned that BASH reads scripts one line at a time as it runs them. If y...
Simon Jaeger @simon@procrastodon.net
Today I learned that BASH reads scripts one line at a time as it runs them. If your script does something tha takes seven minutes, and within those seven minutse you edit the script, BASH will start reading again at the wrong point and weird stuff will happen.
Not sure how I only managed to learn this today, but I thought it was interesting. There are of course ways around this, but the typical on-device script doesn't use them.