Skip to content

Commit 7d9fc6a

Browse files
OliverNocontiloKo
andauthored
fix(versioning): ensure that version is not empty (#4173)
Co-authored-by: tiloKo <[email protected]>
1 parent b18f857 commit 7d9fc6a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

cmd/artifactPrepareVersion.go

+3
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,9 @@ func runArtifactPrepareVersion(config *artifactPrepareVersionOptions, telemetryD
142142
if err != nil {
143143
log.SetErrorCategory(log.ErrorConfiguration)
144144
return errors.Wrap(err, "failed to retrieve version")
145+
} else if len(version) == 0 {
146+
log.SetErrorCategory(log.ErrorConfiguration)
147+
return fmt.Errorf("version is empty - please check versioning configuration")
145148
}
146149
log.Entry().Infof("Version before automatic versioning: %v", version)
147150

0 commit comments

Comments
 (0)