fix: conform to stricter printf usage in Go 1.24 (#16330)

This commit is contained in:
Mathias Fredriksson
2025-01-29 18:06:22 +02:00
committed by GitHub
parent 967a3810f4
commit 9520da338e
13 changed files with 22 additions and 22 deletions
+5 -5
View File
@@ -45,14 +45,14 @@ func (r *RootCmd) publickey() *serpent.Command {
return xerrors.Errorf("create codersdk client: %w", err)
}
cliui.Infof(inv.Stdout,
cliui.Info(inv.Stdout,
"This is your public key for using "+pretty.Sprint(cliui.DefaultStyles.Field, "git")+" in "+
"Coder. All clones with SSH will be authenticated automatically 🪄.",
)
cliui.Infof(inv.Stdout, pretty.Sprint(cliui.DefaultStyles.Code, strings.TrimSpace(key.PublicKey))+"\n")
cliui.Infof(inv.Stdout, "Add to GitHub and GitLab:")
cliui.Infof(inv.Stdout, "> https://github.com/settings/ssh/new")
cliui.Infof(inv.Stdout, "> https://gitlab.com/-/profile/keys")
cliui.Info(inv.Stdout, pretty.Sprint(cliui.DefaultStyles.Code, strings.TrimSpace(key.PublicKey))+"\n")
cliui.Info(inv.Stdout, "Add to GitHub and GitLab:")
cliui.Info(inv.Stdout, "> https://github.com/settings/ssh/new")
cliui.Info(inv.Stdout, "> https://gitlab.com/-/profile/keys")
return nil
},