Scroll to navigation

hub-compare(1) hub manual hub-compare(1)

NAME

hub-compare - Open a GitHub compare page in a web browser.

SYNOPSIS

hub compare [-uc] [-b BASE]
hub compare [-uc] [OWNER] [BASE...]HEAD

OPTIONS

-u, --url

Print the URL instead of opening it.

-c, --copy

Put the URL to clipboard instead of opening it.

-b, --base BASE

Base branch to compare against in case no explicit arguments were given.

[BASE...]HEAD

Branch names, tag names, or commit SHAs specifying the range to compare. If a range with two dots (A..B) is given, it will be transformed into a range with three dots.

The BASE portion defaults to the default branch of the repository.

The HEAD argument defaults to the current branch. If the current branch is not pushed to a remote, the command will error.

OWNER

Optionally specify the owner of the repository for the compare page URL.

EXAMPLES

SEE ALSO

hub-browse(1), hub(1)

05 Aug 2023 hub version 2.14.2