Fix #284: Do not checkout the branch if a commit or PR is specified.