git: Fix using tags/branches with shallow_clone enabled
Previously it would always fail because it tried:
git clone --depth=1 ... && git checkout $tag
Now we both clone the tag/branch directly but also use --no-single-branch to pull information about other tags/branches to checkout.