fix(node): tag .pkg as installer variant alongside .msi

The macOS .pkg is a pkgutil installer, not a plain archive.
Tagged as installer so it's excluded from legacy export but
available for Go's native installer support.
This commit is contained in:
AJ ONeal
2026-03-10 17:01:47 -06:00
parent cdec995183
commit 68ecaf2fbc

View File

@@ -4,13 +4,13 @@ import "github.com/webinstall/webi-installers/internal/storage"
// TagVariants tags node-specific build variants.
//
// .msi is a Windows installer. .exe is the bare node.exe binary — valid
// and installable by Go, but not present in the legacy Node.js cache
// (the nodedist classifier doesn't construct that filename).
// - .msi Windows installer
// - .pkg — macOS installer (pkgutil --expand-full)
// - .exe — bare node.exe without npm, too minimal to be useful
func TagVariants(assets []storage.Asset) {
for i := range assets {
switch assets[i].Format {
case ".msi":
case ".msi", ".pkg":
assets[i].Variants = append(assets[i].Variants, "installer")
case ".exe":
assets[i].Variants = append(assets[i].Variants, "bare-exe")