From 5f66cb1ca2f31ddbbdff34be5e3561584cd67d4b Mon Sep 17 00:00:00 2001 From: Nikolay Edigaryev Date: Sun, 16 Feb 2025 01:03:05 +0400 Subject: [PATCH] Use "-productVersion" instead of "--productVersion" to support Monterey (#215) * Use "-productVersion" instead of "--productVersion" to support Monterey * No need to relocate anything as we're starting from scratch (IPSW) --- templates/resolve-macos-number.pkr.hcl | 4 +++- templates/vanilla-monterey.pkr.hcl | 2 +- templates/vanilla-sequoia.pkr.hcl | 2 +- templates/vanilla-sonoma.pkr.hcl | 2 +- templates/vanilla-ventura.pkr.hcl | 2 +- 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/templates/resolve-macos-number.pkr.hcl b/templates/resolve-macos-number.pkr.hcl index bba5708..e067b12 100644 --- a/templates/resolve-macos-number.pkr.hcl +++ b/templates/resolve-macos-number.pkr.hcl @@ -34,7 +34,9 @@ build { provisioner "shell" { inline = [ - "sw_vers --productVersion > /tmp/sw-vers-product-version.txt", + # Use "-productVersion" instead of "--productVersion" + # to support old-style syntax used on macOS Monterey + "sw_vers -productVersion > /tmp/sw-vers-product-version.txt", ] } diff --git a/templates/vanilla-monterey.pkr.hcl b/templates/vanilla-monterey.pkr.hcl index 1f8b32e..57d5c51 100644 --- a/templates/vanilla-monterey.pkr.hcl +++ b/templates/vanilla-monterey.pkr.hcl @@ -85,7 +85,7 @@ source "tart-cli" "tart" { create_grace_time = "30s" // Keep the recovery partition, otherwise it's not possible to "softwareupdate" - recovery_partition = "relocate" + recovery_partition = "keep" } build { diff --git a/templates/vanilla-sequoia.pkr.hcl b/templates/vanilla-sequoia.pkr.hcl index 300ad5c..d7361a4 100644 --- a/templates/vanilla-sequoia.pkr.hcl +++ b/templates/vanilla-sequoia.pkr.hcl @@ -89,7 +89,7 @@ source "tart-cli" "tart" { create_grace_time = "30s" // Keep the recovery partition, otherwise it's not possible to "softwareupdate" - recovery_partition = "relocate" + recovery_partition = "keep" } build { diff --git a/templates/vanilla-sonoma.pkr.hcl b/templates/vanilla-sonoma.pkr.hcl index b61e50b..df72b4a 100644 --- a/templates/vanilla-sonoma.pkr.hcl +++ b/templates/vanilla-sonoma.pkr.hcl @@ -84,7 +84,7 @@ source "tart-cli" "tart" { create_grace_time = "30s" // Keep the recovery partition, otherwise it's not possible to "softwareupdate" - recovery_partition = "relocate" + recovery_partition = "keep" } build { diff --git a/templates/vanilla-ventura.pkr.hcl b/templates/vanilla-ventura.pkr.hcl index 57024d4..1782d4c 100644 --- a/templates/vanilla-ventura.pkr.hcl +++ b/templates/vanilla-ventura.pkr.hcl @@ -92,7 +92,7 @@ source "tart-cli" "tart" { create_grace_time = "30s" // Keep the recovery partition, otherwise it's not possible to "softwareupdate" - recovery_partition = "relocate" + recovery_partition = "keep" } build {