Presumably if someone has this script they've already done this since the script would be in the github repo?  This might then just reclone everything.

Might be good to test whether we're in a git repo already before doing this (and then likewise, not cd to nmatrix below, as well as test for Gemfile instead of nmatrix/Gemfile if we're in the repository.  Actually, you might want to check whether they're in the repository in the scripts directory or the base directory of the repository too and cd to the base directory if they're in /scripts.)