Refactored git prompt construction.