From 5feed51c61668e920d773cee3aa6151d61929237 Mon Sep 17 00:00:00 2001 From: Guofang Date: Fri, 16 Oct 2026 17:45:55 +0800 Subject: [PATCH] Locate the answer media by its CIDATA volume label in Autounattend.xml Shorten the first-logon CommandLine and stop depending on a drive letter. Co-Authored-By: Claude Sonnet 5.5 --- seediso/windows11/Autounattend.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/seediso/windows11/Autounattend.xml b/seediso/windows11/Autounattend.xml index 3aa571f..5024bb2 100644 --- a/seediso/windows11/Autounattend.xml +++ b/seediso/windows11/Autounattend.xml @@ -162,7 +162,7 @@ 1 Configure Windows from the answer-media script - powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "$script = Get-ChildItem -Path (Get-PSDrive -PSProvider FileSystem).Root -Filter 'Configure-Windows.ps1' -File -ErrorAction SilentlyContinue | Select-Object -First 1; if (-not $script) { throw 'Configure-Windows.ps1 was not found on the attached media.' }; & $script.FullName -InstallVirtIO -EnableAutomaticLogon -DisableAutoUpdate -CopyInstallers -NoPause" + powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "& ('{0}:\Configure-Windows.ps1' -f (Get-Volume -FileSystemLabel CIDATA).DriveLetter) -InstallVirtIO -EnableAutomaticLogon -DisableAutoUpdate -CopyInstallers -NoPause" false