From 5bf079120f5fd301718d2df36709b418ec0b3b95 Mon Sep 17 00:00:00 2001 From: Austin Abro <37223396+AustinAbro321@users.noreply.github.com> Date: Thu, 5 Dec 2024 09:21:22 -0500 Subject: [PATCH] feat: allow init packages to be explicitly versioned (#3286) Signed-off-by: Austin Abro --- src/internal/packager2/layout/create.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/internal/packager2/layout/create.go b/src/internal/packager2/layout/create.go index 17856a0654..d52352d1ae 100644 --- a/src/internal/packager2/layout/create.go +++ b/src/internal/packager2/layout/create.go @@ -302,7 +302,7 @@ func recordPackageMetadata(pkg v1alpha1.ZarfPackage, flavor string, registryOver hostname, _ := os.Hostname() pkg.Build.Terminal = hostname - if pkg.IsInitConfig() { + if pkg.IsInitConfig() && pkg.Metadata.Version == "" { pkg.Metadata.Version = config.CLIVersion }