change directory and get the new branch before pulling