Skip to content

Commit

Permalink
Print artifact source and revision only when available
Browse files Browse the repository at this point in the history
Signed-off-by: Ilya Dmitrichenko <errordeveloper@gmail.com>
  • Loading branch information
errordeveloper authored and stefanprodan committed Oct 12, 2023
1 parent e9d4b42 commit b46e298
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions cmd/flux/pull_artifact.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,12 @@ func pullArtifactCmdRun(cmd *cobra.Command, args []string) error {
return err
}

logger.Successf("source %s", meta.Source)
logger.Successf("revision %s", meta.Revision)
if meta.Source != "" {
logger.Successf("source %s", meta.Source)
}
if meta.Revision != "" {
logger.Successf("revision %s", meta.Revision)
}
logger.Successf("digest %s", meta.Digest)
logger.Successf("artifact content extracted to %s", pullArtifactArgs.output)

Expand Down

0 comments on commit b46e298

Please sign in to comment.