Added method to change branch by regexp