「マイクロソフト系技術情報 Wiki」は、「Open棟梁Project」,「OSSコンソーシアム .NET開発基盤部会」によって運営されています。
winget install --id GitHub.cli
winget upgrade --id GitHub.cli|
brew install gh
brew upgrade gh
何気に、インストール後、シェル再起動が必要。
gh --version
gh auth login
? Where do you use GitHub? GitHub.com ? What is your preferred protocol for Git operations on this host? HTTPS ? Authenticate Git with your GitHub credentials? Yes ? How would you like to authenticate GitHub CLI? Login with a web browser ! First copy your one-time code: XXXX-XXXX Press Enter to open https://github.com/login/device in your browser... ✓ Authentication complete. - gh config set -h github.com git_protocol https ✓ Configured git protocol ✓ Logged in as XXXXXXXXXXXX
gh auth status
github.com ✓ Logged in to github.com account XXXXXXXXXXXX (keyring) - Active account: true - Git operations protocol: https - Token: gho_************************************ - Token scopes: 'gist', 'read:org', 'repo', 'workflow' ✓ Logged in to github.com account YYYYYYYYYYYY (keyring) - Active account: false - Git operations protocol: https - Token: gho_************************************ - Token scopes: 'gist', 'read:org', 'repo', 'workflow'
gh auth switch
gh auth switch --user XXXXXXXXXXXX
gh auth logout
gh auth logout --user XXXXXXXXXXXX