helper functions to handle git branches