Gh: Difference between revisions
Jump to navigation
Jump to search
Line 32: | Line 32: | ||
gh repo clone <org>/<repo-name> | gh repo clone <org>/<repo-name> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Revision as of 20:54, 2 May 2022
External
Internal
Overview
GitHub-specific CLI. Can be used to authenticate, clone repositories, etc.
Installation
Mac
brew install gh
Linux
Authentication
==Configure Git to use
Authentication Status
gh auth status --hostname enterprise.internal --show-token
Authenticate with a Personal Access Token
gh auth login --hostname enterprise.internal --with-token < mytoken.txt
gh auth --hostname github.mycompany.com status
Logout
gh auth --hostname github.mycompany.com logout
Clone Repository
gh repo clone <org>/<repo-name>