extract 'parse_git_branch' script