handle non-shallow clones

For local clones and clones by travis of repos with less than 50 commits `git fetch --unshallow` was throwing a fatal error.

Also, it's probably a little cleaner to do repo manipulation stuff in the `before_install` section.