Move git configuration before the cleanup