handle error if we're not in a repo