hub-compare(1)

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

SYNOPSIS

hub compare [-uc] [USER] [[START...]END]
hub compare [-uc] [-b BASE]

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.

[START...]END
    Branch names, tag names, or commit SHAs specifying the range to compare. END defaults to the current branch name.

    If a range with two dots (A..B) is given, it will be transformed into a range with three dots.

EXAMPLES

    $ hub compare refactor
    > open https://github.com/USER/REPO/compare/refactor
    $ hub compare v1.0..v1.1
    > open https://github.com/USER/REPO/compare/v1.0...v1.1
    $ hub compare -u jingweno feature
    > echo https://github.com/jingweno/REPO/compare/feature

SEE ALSO

hub-browse(1), hub(1)