logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

gh-auth-setup-git - Setup git with GitHub CLI

Description

       This  command  configures  git  to  use  GitHub  CLI as a credential helper.  For more information on git
       credential helpers please reference: https://git-scm.com/docs/gitcredentials.

       By default, GitHub CLI will be set as the credential helper for all authenticated hosts.  If there is  no
       authenticated hosts the command fails with an error.

       Alternatively,  use  the  --hostname  flag to specify a single host to be configured.  If the host is not
       authenticated with, the command fails with an error.

Example

       # Configure git to use GitHub CLI as the credential helper for all authenticated hosts
       $ gh auth setup-git

       # Configure git to use GitHub CLI as the credential helper for enterprise.internal host
       $ gh auth setup-git --hostname enterprise.internal

Name

       gh-auth-setup-git - Setup git with GitHub CLI

Options

-f, --force<--hostname>
              Force setup even if the host is not known. Must be used in conjunction with --hostname

       -h, --hostname<string>
              The hostname to configure git for

See Also

gh-auth(1)

                                                    Jan 2025                                GH-AUTH-SETUP-GIT(1)

Synopsis

ghauthsetup-git[flags]

See Also