printAuthWarnings writes each warning recorded by authCfg to w, prefixed with a warning icon.
(w io.Writer, cs *iostreams.ColorScheme, authCfg gh.AuthConfig)
| 349 | |
| 350 | // printAuthWarnings writes each warning recorded by authCfg to w, prefixed with a warning icon. |
| 351 | func printAuthWarnings(w io.Writer, cs *iostreams.ColorScheme, authCfg gh.AuthConfig) { |
| 352 | for _, warning := range authCfg.Warnings() { |
| 353 | // Indent continuation lines so a multi-line warning reads as one item. |
| 354 | fmt.Fprintf(w, "%s %s\n", cs.WarningIcon(), strings.ReplaceAll(warning, "\n", "\n ")) |
| 355 | } |
| 356 | } |
| 357 | |
| 358 | func checkForUpdate(ctx context.Context, f *cmdutil.Factory, currentVersion string) (*update.ReleaseInfo, error) { |
| 359 | if updaterEnabled == "" || !update.ShouldCheckForUpdate() { |