Improve robustness of git log regex