Removed '# ' from ${branch_pattern}, because the pattern didn't match on git 1.8.5.2