You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Opens a GitHub Pull Request preview page from the current local branch to the default branch
Optionally you can specify the head and base target branch yourself as arguments
Useful to call from aliases/functions to quickly open a PR. See .bash.d/git.sh where this is used via github_push_pr_preview.sh to automated this workflow with a handful of keystrokes
Prints the Pull Request URL, and if on Mac or if \$BROWSER is set then opens it for you in your default browser
Assumes that GitHub is the remote origin, and checks for this for safety
"
# used by usage() in lib/utils.sh
# shellcheck disable=SC2034
usage_args="[<target_base_branch> <head_branch>]"
help_usage "$@"
#min_args 1 "$@"
max_args 2 "$@"
check_github_origin
owner_repo="$(github_origin_owner_repo)"
# checks are done inside github_origin_owner_repo() now
#if [ -z "$owner_repo" ]; then
# die 'Failed to find origin remote pointing to github.com! Are we in a github checkout?'