Fix refpath and checkout $GIT_COMMIT even if $GITHUB_PR_NUMBER is
specified