Given that bash hasn't a native goto function, I stumbled upon this comment here a while ago.
And while I get, this is a messy solution, it worked very well for my use cases - until now. A few days ago I discovered that the script in which a had such jump marks suddenly quits with an error:
sed: 1: "/myjumpmark:/{:a;n;p;ba};": unexpected EOF (pending }'s)
That's strange, as I didn't touch the script in a while. What I instead discovered, is that brew (I'm running the script on macOS) updated gnu-sed
to version 4.8 in the past days. That's about the time, the problems started.
Now my question is: Is there any significant change in sed 4.8 that causes my previously functioning script to crash? And if so, what should I try to get it to work again?