Only install git and pip if necessary