I use ASDF and it's very good to manage versions, specially if you have multiple projects with different versions of go or node, for example.
You don't even need to manually switch, you can set a version per folder!
Of course, the thing about bash scripts is that they are super specialized to do one thing, that usually only really works for the creator's workflow.