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 <[email protected]>
  • Loading branch information
errordeveloper committed Sep 27, 2023
1 parent b4dcfb3 commit 07ce08b
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 07ce08b

Please sign in to comment.