Fix git rev-parse for certain cases