From fc9bf6e7653166859fd5dc8e93bc3bdfb6d27c0a Mon Sep 17 00:00:00 2001 From: Austin Abro Date: Wed, 9 Oct 2024 16:10:54 +0000 Subject: [PATCH] implement for the others Signed-off-by: Austin Abro --- src/pkg/message/credentials.go | 30 ++++++++++++------------------ 1 file changed, 12 insertions(+), 18 deletions(-) diff --git a/src/pkg/message/credentials.go b/src/pkg/message/credentials.go index ae99d3e6f7..0ef1029146 100644 --- a/src/pkg/message/credentials.go +++ b/src/pkg/message/credentials.go @@ -99,24 +99,18 @@ func PrintCredentialUpdates(oldState *types.ZarfState, newState *types.ZarfState HorizontalRule() switch service { - // case RegistryKey: - // oR := oldState.RegistryInfo - // nR := newState.RegistryInfo - // Title("Registry", "the information used to interact with Zarf's container image registry") - // pterm.Println() - // logger.Info("Registry information", compareStrings(oR.Address, nR.Address), - // compareStrings(oR.PushUsername, nR.PushUsername), comparePasswords(oR.PushPassword, nR.PushPassword), - // compareStrings(oR.PullUsername, nR.PullUsername), comparePasswords(oR.PullPassword, nR.PullPassword)) - // case GitKey: - // oG := oldState.GitServer - // nG := newState.GitServer - // Title("Git Server", "the information used to interact with Zarf's GitOps Git Server") - // pterm.Println() - // pterm.Printfln(" %s: %s", pterm.Bold.Sprint("URL Address"), compareStrings(oG.Address, nG.Address, false)) - // pterm.Printfln(" %s: %s", pterm.Bold.Sprint("Push Username"), compareStrings(oG.PushUsername, nG.PushUsername, false)) - // pterm.Printfln(" %s: %s", pterm.Bold.Sprint("Push Password"), compareStrings(oG.PushPassword, nG.PushPassword, true)) - // pterm.Printfln(" %s: %s", pterm.Bold.Sprint("Pull Username"), compareStrings(oG.PullUsername, nG.PullUsername, false)) - // pterm.Printfln(" %s: %s", pterm.Bold.Sprint("Pull Password"), compareStrings(oG.PullPassword, nG.PullPassword, true)) + case RegistryKey: + oR := oldState.RegistryInfo + nR := newState.RegistryInfo + logger.Info("Registry information", compareStrings("URL Address", oR.Address, nR.Address), + compareStrings("Push Username", oR.PushUsername, nR.PushUsername), comparePasswords("Push Password", oR.PushPassword, nR.PushPassword), + compareStrings("Pull Username", oR.PullUsername, nR.PullUsername), comparePasswords("Push Password", oR.PullPassword, nR.PullPassword)) + case GitKey: + oG := oldState.GitServer + nG := newState.GitServer + logger.Info("Git Server info", compareStrings("URL Address", oG.Address, nG.Address), + compareStrings("Push Username", oG.PushUsername, nG.PushUsername), comparePasswords("Push Password", oG.PushPassword, nG.PushPassword), + compareStrings("Pull Username", oG.PullUsername, nG.PullUsername), comparePasswords("Push Password", oG.PullPassword, nG.PullPassword)) case ArtifactKey: oA := oldState.ArtifactServer nA := newState.ArtifactServer