Skip to content.
Joe Heaton's Webzone
🥐 ☕
Online since 2011

Github CLI headless install

Download & Install Github CLI.

Run gh pr status, you will be prompted to connect gh to your Github account, open the github.com link it generates in a web browser, login and authorize the application. You will be redirected to a localhost address, copy the full address.

Now you will need another terminal open one the same system, use wget/curl to pass the authorization onto the gh client:

wget -O- GITHUB_URL

curl GITHUB_URL

Navigate to a git clone with a github.com upstream and start using gh.

Some uses:

> gh help
Work seamlessly with GitHub from the command line.

GitHub CLI is in early stages of development, and we'd love to hear your
feedback at <https://forms.gle/umxd3h31c7aMQFKG7>

Usage:
  gh [command]

Available Commands:
  help        Help about any command
  issue       Create and view issues
  pr          Create, view, and checkout pull requests

Flags:
      --help              Show help for command
  -R, --repo OWNER/REPO   Select another repository using the OWNER/REPO format
      --version           Show gh version

Use "gh [command] --help" for more information about a command.
> gh issue list
> gh issue status
> gh pr list
> gh pr status

Settings!