MCPcopy Create free account
hub / github.com/cli/cli / reload

Method reload

internal/config/refreshable.go:133–138  ·  view source on GitHub ↗

reload re-reads the config from disk into the shared config, using the reloadConfig seam when set and the real ghConfig.Reload otherwise. The production fallback passes fallbackConfig so a config file deleted between reads is restored to gh's defaults, matching NewConfig.

()

Source from the content-addressed store, hash-verified

131// ghConfig.Reload otherwise. The production fallback passes fallbackConfig so a config file deleted between reads is
132// restored to gh's defaults, matching NewConfig.
133func (c *AuthConfig) reload() error {
134 if c.reloadConfig != nil {
135 return c.reloadConfig()
136 }
137 return ghConfig.Reload(fallbackConfig())
138}
139
140// LoginRefreshable stores a refreshable credential for the user, sets the git protocol, and activates the user. It
141// mirrors Login: secure storage is preferred and the insecure configuration is used as a fallback, reported via the

Callers 1

Calls 1

fallbackConfigFunction · 0.85

Tested by

no test coverage detected