Since we're cloning a particular branch with git clone --shallow,
assume we're still passed a branch that contains the commit. Otherwise
we'd waste time and space cloning all the branches in the repo.
Assume that this is only used for checking out a particular sha1 once,
to avoid repetitive work.
There are two use cases for these utilities:
1) on the user's machine when they're scheduling a suite - there it
will make sense to maintain a single checkout of a branch e.g. teuthology master
2) on the queue consumer side - here it's best if we use the same commit for an
entire run, so checking out by sha1 makes more sense