gh auth

Authenticate with a GitHub host. More information: https://cli.github.com/manual/gh_auth.

gh auth login

echo {{your_token}} | gh auth login --with-token

gh auth status

gh auth logout

gh auth login --hostname {{github.example.com}}

gh auth refresh

gh auth refresh --scopes {{repo,admin:repo_hook,admin:org,admin:public_key,admin:org_hook,...}}