From ec199d7f3d3538b8a5b66f62827de4b9d64209a9 Mon Sep 17 00:00:00 2001 From: "Michael H.G. Schmidt" Date: Fri, 25 Dec 2020 20:08:46 +0100 Subject: [PATCH] . --- PrepareStick.cmd | 24 ++ RunScriptTest.cmd | 11 +- SetupComplete.cmd | 9 + SetupComplete.ps1 | 8 + autounattend.xml | 24 +- wimscripts/Packages-sorted.txt | 628 ------------------------------- wimscripts/RunScriptTest.cmd | 6 +- wimscripts/SetupComplete.cmd | 31 +- wimscripts/SetupComplete.ps1 | 10 - wimscripts/export-image.cmd | 2 +- wimscripts/finish-image.cmd | 18 +- wimscripts/mount-wim.cmd | 2 - wimscripts/remove-components.cmd | 167 -------- 13 files changed, 99 insertions(+), 841 deletions(-) create mode 100644 PrepareStick.cmd create mode 100644 SetupComplete.cmd create mode 100644 SetupComplete.ps1 delete mode 100644 wimscripts/Packages-sorted.txt delete mode 100644 wimscripts/SetupComplete.ps1 delete mode 100644 wimscripts/remove-components.cmd diff --git a/PrepareStick.cmd b/PrepareStick.cmd new file mode 100644 index 0000000..cbb8ce0 --- /dev/null +++ b/PrepareStick.cmd @@ -0,0 +1,24 @@ +@echo off +set TARGET=D: +set TESTSCRIPT=1st-logon.cmd +set SOURCES=c:\TEMP\Win10\sources + +echo ####### %0 ####### + +if EXIST %SOURCES%\install_FINAL.esd ( + robocopy %SOURCES% %TARGET%\sources install_FINAL.esd + del /Q %TARGET%\sources\install.esd 1>nul 2>nul + move %TARGET%\sources\install_FINAL.esd %TARGET%\sources\install.esd + move %SOURCES%\install_FINAL.esd %SOURCES%\install_FINAL_copy.esd +) + +copy /Y autounattend.xml %TARGET%\ +copy /Y 1st-logon.cmd %TARGET%\ +copy /Y ToolsDownload.ftp %TARGET%\ +copy /Y SetupComplete.cmd %TARGET%\ +copy /Y SetupComplete.ps1 %TARGET%\ + +echo ####### %0 ####### + +rem call %TARGET%\%TESTSCRIPT% + diff --git a/RunScriptTest.cmd b/RunScriptTest.cmd index 318d2df..fc99524 100644 --- a/RunScriptTest.cmd +++ b/RunScriptTest.cmd @@ -1,11 +1,16 @@ @echo off +set TARGET=D: +set TESTSCRIPT=1st-logon.cmd echo ####### %0 ####### -copy /Y 1st-logon.cmd D:\ -copy /Y ToolsDownload.ftp D:\ +copy /Y autounattend.xml %TARGET%\ +copy /Y 1st-logon.cmd %TARGET%\ +copy /Y ToolsDownload.ftp %TARGET%\ +copy /Y SetupComplete.cmd %TARGET%\ +copy /Y SetupComplete.ps1 %TARGET%\ echo ####### %0 ####### -call D:\1st-logon.cmd +rem call %TARGET%\%TESTSCRIPT% diff --git a/SetupComplete.cmd b/SetupComplete.cmd new file mode 100644 index 0000000..ebaf9e7 --- /dev/null +++ b/SetupComplete.cmd @@ -0,0 +1,9 @@ +@echo off +rem SetupComplete.cmd ... + +echo ####### %0 ####### + +echo [ place your code here ] ... + +echo ####### %0 ####### + diff --git a/SetupComplete.ps1 b/SetupComplete.ps1 new file mode 100644 index 0000000..c0ccaa5 --- /dev/null +++ b/SetupComplete.ps1 @@ -0,0 +1,8 @@ +# SetupComplete.ps1 ... + +write-host '#######',(split-path $PSCommandPath -Leaf),'#######' + +echo "[ place your code here ] ..." + +write-host '#######',(split-path $PSCommandPath -Leaf),'#######' + diff --git a/autounattend.xml b/autounattend.xml index 4bd2c62..12ccefe 100644 --- a/autounattend.xml +++ b/autounattend.xml @@ -157,26 +157,26 @@ cmd /C wmic useraccount where name="support" set PasswordExpires=false Password Never Expires - - 7 - cmd /C D:\1st-logon.cmd - Initial Setup - - - 4 - Turn Firewall OFF - cmd /C netsh advfirewall set allprofiles state off - reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f - 5 + 4 Disable Windows Hi Animation (Part1) - 6 + 5 Disable Windows Hi Animation (Part2) reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f + + 6 + Enable outgoing ftp + cmd /C netsh advfirewall firewall add rule name="ftp" service=ftp dir=out action=allow profile=any + + + 7 + cmd /C D:\1st-logon.cmd + Initial Setup + diff --git a/wimscripts/Packages-sorted.txt b/wimscripts/Packages-sorted.txt deleted file mode 100644 index 71fb5a5..0000000 --- a/wimscripts/Packages-sorted.txt +++ /dev/null @@ -1,628 +0,0 @@ -Containers-ApplicationGuard-Package -Containers-ApplicationGuard-Shared-Package -Containers-ApplicationGuard-Shared-WOW64-Package -Containers-ApplicationGuard-Shared-merged-Package -Containers-ApplicationGuard-WOW64-Package -Containers-Client-Guest-Package -Containers-Client-Manager-Package -Containers-Client-Manager-merged-Package -Containers-Client-Shared-Package -Containers-DisposableClientVM-Package -Containers-DisposableClientVM-merged-Package -Containers-Guest-Gated-Package -Containers-Guest-Gated-WOW64-Package -Containers-OptionalFeature-DisposableClientVM-Package -Containers-Server-Package -Containers-Server-merged-Package -DiskIo-QoS-Package -HyperV-Compute-Host-Containers-Package -HyperV-Compute-Host-Containers-merged-Package -HyperV-Compute-Host-Package -HyperV-Compute-Host-VirtualMachines-Package -HyperV-Compute-Host-VirtualMachines-merged-Package -HyperV-Compute-Host-merged-Package -HyperV-Compute-Storage-Package -HyperV-Compute-Storage-merged-Package -HyperV-Compute-System-VirtualMachine-Package -HyperV-Compute-System-VirtualMachine-merged-Package -HyperV-Compute-System-VmDirect-Package -HyperV-Compute-System-VmDirect-merged-Package -HyperV-DynamicMemory-VirtualDevice-Package -HyperV-Feature-ApplicationGuard-Package -HyperV-Feature-Containers-Package -HyperV-Feature-VirtualMachinePlatform-Package -HyperV-Guest-KMCL-Package -HyperV-Guest-KernelInt-Package -HyperV-Guest-KernelInt-merged-Package -HyperV-Host-Compute-Interop-Package -HyperV-Host-Compute-PowerShell-Module-Package -HyperV-Host-Compute-PowerShell-Module-merged-Package -HyperV-Host-Devices-EmulatedChipset-Package -HyperV-Host-Devices-EmulatedChipset-merged-Package -HyperV-HvSocket-Package -HyperV-Hypervisor-Package -HyperV-HypervisorPlatform-Package -HyperV-HypervisorPlatform-merged-Package -HyperV-IntegrationComponents-VirtualDevice-Core-Package -HyperV-IntegrationComponents-VirtualDevice-Server-Package -HyperV-IsolatedVM-SVC-Package -HyperV-IsolatedVm-Package -HyperV-KMCL-Host-Package -HyperV-KernelInt-VSP-Package -HyperV-KernelInt-VSP-merged-Package -HyperV-KernelInt-VirtualDevice-Package -HyperV-KernelInt-VirtualDevice-merged-Package -HyperV-Networking-Containers-Package -HyperV-Networking-Containers-merged-Package -HyperV-Networking-Package -HyperV-Networking-VirtualDevice-Emulated-Package -HyperV-Networking-VirtualDevice-Synthetic-Package -HyperV-Networking-VirtualDevice-Synthetic-merged-Package -HyperV-Networking-merged-Package -HyperV-Primitive-VirtualMachine-Package -HyperV-RDP4VS-Package -HyperV-RDP4VS-merged-Package -HyperV-Storage-QoS-Package -HyperV-Storage-VSP-Package -HyperV-Storage-VSP-merged-Package -HyperV-Storage-VirtualDevice-FibreChannel-Package -HyperV-Storage-VirtualDevice-FibreChannel-merged-Package -HyperV-Storage-VirtualDevice-IDE-Package -HyperV-Storage-VirtualDevice-IDE-merged-Package -HyperV-Storage-VirtualDevice-PMEM-Package -HyperV-Storage-VirtualDevice-PMEM-merged-Package -HyperV-Storage-VirtualDevice-SCSI-Package -HyperV-Storage-VirtualDevice-SCSI-merged-Package -HyperV-Storage-VirtualDevice-SMB-Package -HyperV-Storage-VirtualDevice-SMB-merged-Package -HyperV-UX-Common-Package -HyperV-UX-PowerShell-Module-HyperV-Package -HyperV-UX-PowerShell-Module-HyperV-WOW64-Package -HyperV-UX-PowerShell-Module-HyperV-merged-Package -HyperV-UX-UI-62-Package -HyperV-UX-UI-62-merged-Package -HyperV-UX-UI-63-Package -HyperV-UX-UI-63-merged-Package -HyperV-UX-UI-Client-Package -HyperV-UX-UI-Client-merged-Package -HyperV-UX-UI-Package -HyperV-UX-UI-merged-Package -HyperV-VID-Package -HyperV-VMMS-Package -HyperV-VMMS-merged-Package -HyperV-Virtio-Package -HyperV-VmBus-Host-Package -HyperV-VmBus-Host-merged-Package -HyperV-VmBus-VirtualDevice-Package -HyperV-VmBus-VirtualDevice-merged-Package -HyperV-VmChipset-Package -HyperV-VmSerial-Package -HyperV-VmTpm-Package -HyperV-VmUiDevices-Package -HyperV-Vpci-VSP-Package -HyperV-Vpci-VSP-merged-Package -HyperV-Vpci-VirtualDevice-DDA-Package -HyperV-Vpci-VirtualDevice-DDA-merged-Package -HyperV-Vpci-VirtualDevice-FlexIo-Package -HyperV-Vpci-VirtualDevice-FlexIo-merged-Package -HyperV-Vpci-VirtualDevice-Gpup-Package -HyperV-Vpci-VirtualDevice-Gpup-merged-Package -HyperV-Worker-Package -HyperV-Worker-merged-Package -LanguageFeatures-WordBreaking-de-Package -LanguageFeatures-WordBreaking-de-WOW64-Package -LanguageFeatures-WordBreaking-de-legacy-Package -LanguageFeatures-WordBreaking-de-legacy-WOW64-Package -MSMQ-Driver-Package -Microsoft-Client-License-Platform-Upgrade-Subscription-Package -Microsoft-Composable-PlatformExtension-DragDropCommon-Package -Microsoft-Composable-PlatformExtension-DragDropCommon-WOW64-Package -Microsoft-Hyper-V-ClientEdition-Package -Microsoft-Hyper-V-ClientEdition-WOW64-Package -Microsoft-Hyper-V-Hypervisor-Package -Microsoft-Hyper-V-Hypervisor-merged-Package -Microsoft-Hyper-V-Offline-Common-Package -Microsoft-Hyper-V-Offline-Common-merged-Package -Microsoft-Hyper-V-Offline-Core-Group-Package -Microsoft-Hyper-V-Offline-Core-Group-merged-Package -Microsoft-Hyper-V-Online-Services-Package -Microsoft-Hyper-V-Online-Services-merged-Package -Microsoft-Hyper-V-Package-base-Package -Microsoft-Hyper-V-Package-base-merged-Package -Microsoft-Hyper-V-Services-Package -Microsoft-IoTUAP-ShellExt-Tools-Package -Microsoft-Media-Foundation-Package -Microsoft-Media-Foundation-WOW64-Package -Microsoft-OneCore-ApplicationModel-Sync-Desktop-FOD-Package -Microsoft-OneCore-Containers-Guest-Package -Microsoft-OneCore-Containers-Guest-Shared-Package -Microsoft-OneCore-Containers-Guest-merged-Package -Microsoft-OneCore-Containers-Package -Microsoft-OneCore-Containers-merged-Package -Microsoft-OneCore-DeviceUpdateCenter-Package -Microsoft-OneCore-DirectX-Database-FOD-Package -Microsoft-OneCore-EventLogAPI-Package -Microsoft-OneCore-Helium-Package -Microsoft-OneCore-Http-Package -Microsoft-OneCore-IsolatedUserMode-Package -Microsoft-OneCore-LibreSSL-Package -Microsoft-OneCore-Multimedia-CastingCommon-Package -Microsoft-OneCore-Multimedia-CastingCommon-WOW64-Package -Microsoft-OneCore-Multimedia-CastingReceiver-Media-Package -Microsoft-OneCore-Multimedia-CastingReceiver-Media-WOW64-Package -Microsoft-OneCore-Multimedia-CastingTransmitter-Media-Package -Microsoft-OneCore-Multimedia-MFPMP-Package -Microsoft-OneCore-Multimedia-MFPMP-WOW64-Package -Microsoft-OneCore-OpenSSH-ClientOnly-Package -Microsoft-OneCore-OpenSSH-Common-Package -Microsoft-OneCore-UtilityVM-Containers-Shared-Package -Microsoft-OneCore-UtilityVM-Containers-Shared-merged-Package -Microsoft-OneCore-UtilityVm-SetupAgent-Package -Microsoft-OneCore-VirtualizationBasedSecurity-Package -Microsoft-OneCoreUAP-AppRuntime-RemoteAppLifetimeManager-Package -Microsoft-Onecore-SPP-VirtualDevice-Package -Microsoft-Shielded-VM-Service-Package -Microsoft-UtilityVM-Containers-Package -Microsoft-UtilityVM-Containers-Setup-Shared-Package -Microsoft-UtilityVM-Containers-Setup-Shared-merged-Package -Microsoft-UtilityVM-Containers-Shared-Package -Microsoft-UtilityVM-Containers-merged-Package -Microsoft-Windows-20H2Enablement-Package -Microsoft-Windows-20H2Enablement-Payload-Package -Microsoft-Windows-ApiSetSchemaExtension-HyperV-ComputeCore-Package -Microsoft-Windows-ApiSetSchemaExtension-HyperV-ComputeLegacy-Package -Microsoft-Windows-ApiSetSchemaExtension-HyperV-ComputeNetwork-Package -Microsoft-Windows-ApiSetSchemaExtension-HyperV-ComputeStorage-Package -Microsoft-Windows-ApiSetSchemaExtension-HyperV-DeviceVirtualization-Package -Microsoft-Windows-AppManagement-AppV-Package -Microsoft-Windows-AppManagement-AppV-WOW64-Package -Microsoft-Windows-AppManagement-Common-Package -Microsoft-Windows-AppManagement-Common-WOW64-Package -Microsoft-Windows-AppManagement-UEV-Package -Microsoft-Windows-AppManagement-UEV-WOW64-Package -Microsoft-Windows-AppServerClient-OptGroup-Package -Microsoft-Windows-AppServerClient-OptGroup-WOW64-Package -Microsoft-Windows-AppServerClient-OptGroup-WOW64-merged-Package -Microsoft-Windows-AppServerClient-OptGroup-merged-Package -Microsoft-Windows-Basic-Http-Minio-Package -Microsoft-Windows-Branding-Enterprise-Package -Microsoft-Windows-Browser-Package -Microsoft-Windows-COM-MSMQ-Package -Microsoft-Windows-Client-AssignedAccess-Package -Microsoft-Windows-Client-AssignedAccess-WOW64-Package -Microsoft-Windows-Client-Desktop-Required-Package -Microsoft-Windows-Client-Desktop-Required-Package00 -Microsoft-Windows-Client-Desktop-Required-Package01 -Microsoft-Windows-Client-Desktop-Required-Package0110 -Microsoft-Windows-Client-Desktop-Required-Package0111 -Microsoft-Windows-Client-Desktop-Required-Package0112 -Microsoft-Windows-Client-Desktop-Required-Package0113 -Microsoft-Windows-Client-Desktop-Required-Package02 -Microsoft-Windows-Client-Desktop-Required-Package03 -Microsoft-Windows-Client-Desktop-Required-Package04 -Microsoft-Windows-Client-Desktop-Required-Package0410 -Microsoft-Windows-Client-Desktop-Required-Package041020 -Microsoft-Windows-Client-Desktop-Required-Package041021 -Microsoft-Windows-Client-Desktop-Required-Package0411 -Microsoft-Windows-Client-Desktop-Required-Package04110 -Microsoft-Windows-Client-Desktop-Required-Package04111 -Microsoft-Windows-Client-Desktop-Required-Package04112 -Microsoft-Windows-Client-Desktop-Required-Package04113 -Microsoft-Windows-Client-Desktop-Required-Package0412 -Microsoft-Windows-Client-Desktop-Required-Package0413 -Microsoft-Windows-Client-Desktop-Required-Package0414 -Microsoft-Windows-Client-Desktop-Required-Package0415 -Microsoft-Windows-Client-Desktop-Required-Package0416 -Microsoft-Windows-Client-Desktop-Required-Package0417 -Microsoft-Windows-Client-Desktop-Required-Package0418 -Microsoft-Windows-Client-Desktop-Required-Package0419 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package -Microsoft-Windows-Client-Desktop-Required-WOW64-Package00 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0010 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package001020 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0011 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0012 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0013 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0014 -Microsoft-Windows-Client-Desktop-Required-WOW64-Package0015 -Microsoft-Windows-Client-EmbeddedExp-Package -Microsoft-Windows-Client-EmbeddedExp-WOW64-Package -Microsoft-Windows-Client-Features-Package -Microsoft-Windows-Client-Features-Package00 -Microsoft-Windows-Client-Features-Package0010 -Microsoft-Windows-Client-Features-Package0011 -Microsoft-Windows-Client-Features-Package01 -Microsoft-Windows-Client-Features-Package02 -Microsoft-Windows-Client-Features-Package0210 -Microsoft-Windows-Client-Features-Package0211 -Microsoft-Windows-Client-Features-Package0212 -Microsoft-Windows-Client-Features-Package0213 -Microsoft-Windows-Client-Features-Package0214 -Microsoft-Windows-Client-Features-Package0215 -Microsoft-Windows-Client-Features-Package0216 -Microsoft-Windows-Client-Features-Package0217 -Microsoft-Windows-Client-Features-Package03 -Microsoft-Windows-Client-Features-Package04 -Microsoft-Windows-Client-Features-Package05 -Microsoft-Windows-Client-Features-Package06 -Microsoft-Windows-Client-Features-WOW64-Package -Microsoft-Windows-Client-Features-WOW64-Package00 -Microsoft-Windows-Client-Features-WOW64-Package0010 -Microsoft-Windows-Client-Features-WOW64-Package0011 -Microsoft-Windows-Client-Features-WOW64-Package0012 -Microsoft-Windows-Client-Features-WOW64-Package01 -Microsoft-Windows-Client-Features-WOW64-Package02 -Microsoft-Windows-Client-LanguagePack-Package -Microsoft-Windows-Client-LanguagePack-Package-Wrapper -Microsoft-Windows-Client-Optional-Features-Package -Microsoft-Windows-Client-ShellLauncher-Package -Microsoft-Windows-ClientForNFS-Infrastructure-OptGroup-Package -Microsoft-Windows-Common-Foundation-Package -Microsoft-Windows-Common-RegulatedPackages-Package -Microsoft-Windows-Common-RegulatedPackages-WOW64-Package -Microsoft-Windows-ConfigCI-Onecore-Package -Microsoft-Windows-ConfigCI-Onecore-WOW64-Package -Microsoft-Windows-ConfigCI-Package -Microsoft-Windows-CoreSystem-DISM-Package -Microsoft-Windows-CoreSystem-RemoteFS-Client-Package -Microsoft-Windows-DataCenterBridging-Opt-Package -Microsoft-Windows-DataCenterBridging-Opt-WOW64-Package -Microsoft-Windows-DataCenterBridging-Package -Microsoft-Windows-DataCenterBridging-WOW64-Package -Microsoft-Windows-Dedup-ChunkLibrary-Package -Microsoft-Windows-Desktop-BCDTemplate-Client-Package -Microsoft-Windows-DesktopFileExplorer-Package -Microsoft-Windows-DeviceGuard-GPEXT-Package -Microsoft-Windows-DirectPlay-OC-Opt-Package -Microsoft-Windows-DirectPlay-OC-Opt-WOW64-Package -Microsoft-Windows-DirectPlay-OC-Package -Microsoft-Windows-DirectPlay-OC-WOW64-Package -Microsoft-Windows-DirectoryServices-ADAM-Client-Admin-Package -Microsoft-Windows-DirectoryServices-ADAM-Client-OptGroup-Package -Microsoft-Windows-DirectoryServices-ADAM-Client-Package -Microsoft-Windows-DirectoryServices-ADAM-Core-Client-Opt-Package -Microsoft-Windows-DirectoryServices-ADAM-Install-Group-Package -Microsoft-Windows-DirectoryServices-ADAM-Snapins-Admin-Package -Microsoft-Windows-DirectoryServices-ADAM-Snapins-Group-Package -Microsoft-Windows-DirectoryServices-ADAM-Tools-Opt-Package -Microsoft-Windows-DirectoryServices-ADAM-Tools-Opt-merged-Package -Microsoft-Windows-EditionPack-Professional-Package -Microsoft-Windows-EditionPack-Professional-WOW64-Package -Microsoft-Windows-EditionSpecific-Professional-Package -Microsoft-Windows-EditionSpecific-Professional-WOW64-Package -Microsoft-Windows-Editions-Professional-Package -Microsoft-Windows-Embedded-AssignedAccessCsp-Package -Microsoft-Windows-Embedded-BootExp-Package -Microsoft-Windows-Embedded-EmbeddedLogon-Package -Microsoft-Windows-Embedded-KeyboardFilter-Package -Microsoft-Windows-Embedded-KeyboardFilter-WOW64-Package -Microsoft-Windows-Embedded-ShellLauncher-Package -Microsoft-Windows-Embedded-UnifiedWriteFilter-Package -Microsoft-Windows-Embedded-UnifiedWriteFilter-WOW64-Package -Microsoft-Windows-Embedded-UnifiedWriteFilterCSP-Package -Microsoft-Windows-Enterprise-Desktop-Shared-Package -Microsoft-Windows-Enterprise-Desktop-Shared-WOW64-Package -Microsoft-Windows-EnterpriseClientSync-Host-Opt-Package -Microsoft-Windows-EnterpriseClientSync-Host-Package -Microsoft-Windows-FCI-Client-Package -Microsoft-Windows-FodMetadata-Package -Microsoft-Windows-Foundation-Package -Microsoft-Windows-GroupPolicy-ClientExtensions-Package -Microsoft-Windows-GroupPolicy-ClientExtensions-WOW64-Package -Microsoft-Windows-GroupPolicy-ClientTools-Package -Microsoft-Windows-GroupPolicy-ClientTools-WOW64-Package -Microsoft-Windows-GroupPolicy-ClientTools-merged-Package -Microsoft-Windows-HVSI-Components-Package -Microsoft-Windows-HVSI-Components-WOW64-Package -Microsoft-Windows-HVSI-Package -Microsoft-Windows-HVSI-WOW64-Package -Microsoft-Windows-Hello-Face-Package -Microsoft-Windows-Hello-Face-Package-Wrapper -Microsoft-Windows-Help-ClientOOBE-Feature-Package -Microsoft-Windows-Help-ClientUA-Client-Package -Microsoft-Windows-Help-ClientUA-Client-merged-Package -Microsoft-Windows-HgsClient-Core-Package -Microsoft-Windows-Holographic-Desktop-Analog-Package -Microsoft-Windows-Holographic-Desktop-Analog-WOW64-Package -Microsoft-Windows-Holographic-Desktop-Merged-Package -Microsoft-Windows-Holographic-Desktop-Merged-WOW64-Package -Microsoft-Windows-Holographic-Desktop-Merged-WOW64-merged-Package -Microsoft-Windows-Holographic-Desktop-Merged-merged-Package -Microsoft-Windows-Host-Guardian-Deployment-Package -Microsoft-Windows-Host-Guardian-Deployment-merged-Package -Microsoft-Windows-HyperV-OptionalFeature-HypervisorPlatform-Disabled-Package -Microsoft-Windows-HyperV-OptionalFeature-HypervisorPlatform-Package -Microsoft-Windows-HyperV-OptionalFeature-VirtualMachinePlatform-Disabled-Package -Microsoft-Windows-HyperV-OptionalFeature-VirtualMachinePlatform-Package -Microsoft-Windows-Hyphenation-Dictionaries-de-Package -Microsoft-Windows-IIS-WebServer-AddOn-2-Package -Microsoft-Windows-IIS-WebServer-AddOn-2-ServerCommon-Package -Microsoft-Windows-IIS-WebServer-AddOn-Package -Microsoft-Windows-IIS-WebServer-AddOn-ServerCommon-Package -Microsoft-Windows-IIS-WebServer-Package -Microsoft-Windows-IIS-WebServer-ServerCommon-Package -Microsoft-Windows-Identity-Foundation-Opt-Package -Microsoft-Windows-Identity-Foundation-Package -Microsoft-Windows-Internet-Browser-Package -Microsoft-Windows-InternetExplorer-Optional-Package -Microsoft-Windows-InternetExplorer-Package-ua -Microsoft-Windows-LanguageFeatures-Basic-de-de-Package -Microsoft-Windows-LanguageFeatures-Handwriting-de-de-Package -Microsoft-Windows-LanguageFeatures-OCR-de-de-Package -Microsoft-Windows-LanguageFeatures-Speech-de-de-Package -Microsoft-Windows-LanguageFeatures-TextToSpeech-de-de-Package -Microsoft-Windows-Legacy-Components-OC-Package -Microsoft-Windows-Legacy-Components-OC-WOW64-Package -Microsoft-Windows-Lxss-Optional-Package -Microsoft-Windows-Lxss-Optional-WOW64-Package -Microsoft-Windows-Lxss-Optional-merged-Package -Microsoft-Windows-Lxss-Package -Microsoft-Windows-Lxss-WOW64-Package -Microsoft-Windows-Lxss-WithGraphics-Package -Microsoft-Windows-Lxss-WithGraphics-WOW64-Package -Microsoft-Windows-Lxss-merged-Package -Microsoft-Windows-MSMQ-Client-Package -Microsoft-Windows-MSMQ-Client-WOW64-Package -Microsoft-Windows-MSMQ-MMC-OptGroup-Package -Microsoft-Windows-MSMQ-MMC-OptGroup-WOW64-Package -Microsoft-Windows-MSPaint-FoD-Package -Microsoft-Windows-Management-SecureAssessment-Package -Microsoft-Windows-Media-Format-Package -Microsoft-Windows-Media-Format-WOW64-Package -Microsoft-Windows-Media-Format-WOW64-merged-Package -Microsoft-Windows-Media-Format-merged-Package -Microsoft-Windows-Media-Streaming-Package -Microsoft-Windows-Media-Streaming-WOW64-Package -Microsoft-Windows-Media-Streaming-WOW64-merged-Package -Microsoft-Windows-Media-Streaming-merged-Package -Microsoft-Windows-MediaPlayback-OC-Package -Microsoft-Windows-MediaPlayer-Package -Microsoft-Windows-MediaPlayer-Package-Wrapper -Microsoft-Windows-MediaPlayer-Payload-Package -Microsoft-Windows-MobilePC-Client-Premium-Package -Microsoft-Windows-MultiPoint-Connector-Package -Microsoft-Windows-Multimedia-MF-Package -Microsoft-Windows-Multimedia-MF-WOW64-Package -Microsoft-Windows-Multimedia-MF-WOW64-merged-Package -Microsoft-Windows-Multimedia-MF-merged-Package -Microsoft-Windows-Multimedia-RestrictedCodecs-Package -Microsoft-Windows-Multimedia-RestrictedCodecs-WOW64-Package -Microsoft-Windows-Multimedia-RestrictedCodecs-WOW64-merged-Package -Microsoft-Windows-Multimedia-RestrictedCodecs-merged-Package -Microsoft-Windows-Multimedia-WMPDMC-Package -Microsoft-Windows-NFS-Administration-D-Opt-Package -Microsoft-Windows-NFS-ClientCore-D-Opt-Package -Microsoft-Windows-NFS-ClientLocalUI-D-Opt-Package -Microsoft-Windows-NFS-ClientSKU-Package -Microsoft-Windows-NetFx-AutoNgenEnable.3.5 -Microsoft-Windows-NetFx-NgenAssemblyExclusionClient -Microsoft-Windows-NetFx-Shared-MOF-Client -Microsoft-Windows-NetFx-Shared-MOF-Extended -Microsoft-Windows-NetFx-Shared-Misc -Microsoft-Windows-NetFx-Shared-Package -Microsoft-Windows-NetFx-Shared-Perfcounters-Client -Microsoft-Windows-NetFx-Shared-Perfcounters-Extended -Microsoft-Windows-NetFx-Shared-Typelibs -Microsoft-Windows-NetFx-Shared-WCF-HttpActivation -Microsoft-Windows-NetFx-Shared-WCF-HttpNamespace -Microsoft-Windows-NetFx-Shared-WCF-MsmqActivation -Microsoft-Windows-NetFx-Shared-WCF-PipeActivation -Microsoft-Windows-NetFx-Shared-WCF-TcpActivation -Microsoft-Windows-NetFx-Shared-WCF-TcpPortSharing -Microsoft-Windows-NetFx-Shared-WPF-Package -Microsoft-Windows-NetFx-Windows-Built-Package -Microsoft-Windows-NetFx2-OC-Package -Microsoft-Windows-NetFx3-OC-Package -Microsoft-Windows-NetFx3-OnDemand-Package -Microsoft-Windows-NetFx3-WCF-OC-Package -Microsoft-Windows-NetFx4-US-OC-Package -Microsoft-Windows-NetFx4-WCF-US-OC-Package -Microsoft-Windows-Network-Connectivity-Assistant-Service-Package -Microsoft-Windows-NetworkDiagnostics-DirectAccessEntry-Package -Microsoft-Windows-NewTabPageHost-Package -Microsoft-Windows-Not-Supported-On-LTSB-Package -Microsoft-Windows-Not-Supported-On-LTSB-WOW64-Package -Microsoft-Windows-Notepad-FoD-Package -Microsoft-Windows-Notepad-FoD-Package-Wrapper -Microsoft-Windows-OfflineFiles-Package -Microsoft-Windows-OfflineFiles-UI-Package -Microsoft-Windows-OfflineFiles-WOW64-Package -Microsoft-Windows-OfflineFiles-merged-Package -Microsoft-Windows-OneCore-Containers-Opt-Package -Microsoft-Windows-OneDrive-Setup-Package -Microsoft-Windows-OneDrive-Setup-WOW64-Package -Microsoft-Windows-PAW-Feature-Package -Microsoft-Windows-PAW-Package -Microsoft-Windows-PAW-merged-Package -Microsoft-Windows-PeerDist-Client-Group-Package -Microsoft-Windows-PeerDist-Client-Group-WOW64-Package -Microsoft-Windows-PeerDist-Client-Package -Microsoft-Windows-PeerDist-Client-WOW64-Package -Microsoft-Windows-PhotoBasic-Feature-Package -Microsoft-Windows-PhotoBasic-Feature-WOW64-Package -Microsoft-Windows-PhotoBasic-Package -Microsoft-Windows-PhotoBasic-PictureTools-Package -Microsoft-Windows-PhotoBasic-PictureTools-WOW64-Package -Microsoft-Windows-PhotoBasic-WOW64-Package -Microsoft-Windows-PhotoBasic-WOW64-merged-Package -Microsoft-Windows-PhotoBasic-merged-Package -Microsoft-Windows-Portable-Devices-Package -Microsoft-Windows-Portable-Devices-WOW64-Package -Microsoft-Windows-Portable-Devices-WOW64-merged-Package -Microsoft-Windows-Portable-Devices-merged-Package -Microsoft-Windows-PowerShell-ISE-FOD-Package -Microsoft-Windows-PowerShell-V2-Client-Package -Microsoft-Windows-Presentation-Package -Microsoft-Windows-Printing-Foundation-Package -Microsoft-Windows-Printing-InternetPrinting-Client-Opt-Package -Microsoft-Windows-Printing-LPDPrintService-Opt-Package -Microsoft-Windows-Printing-LPRPortMonitor-Opt-Package -Microsoft-Windows-Printing-LocalPrinting-Enterprise-Package -Microsoft-Windows-Printing-PMCPPC-FoD-Package -Microsoft-Windows-Printing-PremiumTools-Package -Microsoft-Windows-Printing-PrintToPDF-Opt-Package -Microsoft-Windows-Printing-PrintToPDFServices-Package -Microsoft-Windows-Printing-WFS-FoD-Package -Microsoft-Windows-Printing-WFS-FoD-Package-Wrapper -Microsoft-Windows-Printing-XPSServices-Package -Microsoft-Windows-Printing-XpsDocumentWriter-Opt-Package -Microsoft-Windows-Product-Data-EKB-Package -Microsoft-Windows-Product-Data-EKB-Wrapper-Package -Microsoft-Windows-Professional-SPP-Components-Package -Microsoft-Windows-ProfessionalEdition -Microsoft-Windows-ProfessionalEdition-Wrapper -Microsoft-Windows-ProjFS-OptionalFeature-Package -Microsoft-Windows-ProjFS-Package -Microsoft-Windows-QuickAssist-Package -Microsoft-Windows-RDC-Opt-Package -Microsoft-Windows-RDC-Package -Microsoft-Windows-RegulatedPackages-Package -Microsoft-Windows-RegulatedPackages-WOW64-Package -Microsoft-Windows-RemoteAssistance-Package-Client -Microsoft-Windows-RemoteFX-Graphics-Virtualization-Host-Package -Microsoft-Windows-RemoteFX-HyperV-Integration-Package -Microsoft-Windows-RemoteFX-VM-Setup-Package -Microsoft-Windows-RemoteFX-VM-Setup-WOW64-Package -Microsoft-Windows-RemoteFX-VM-Setup-merged-Package -Microsoft-Windows-Remotefx-Clientvm-Rdvgwddmdx11-Package -Microsoft-Windows-Required-ShellExperiences-Desktop-Package -Microsoft-Windows-Required-ShellExperiences-Desktop-WOW64-Package -Microsoft-Windows-Runtime-Metadata-Desktop-Package -Microsoft-Windows-Runtime-Metadata-Desktop-WOW64-Package -Microsoft-Windows-SMB1-Package -Microsoft-Windows-SMB1Client-D-Opt-Package -Microsoft-Windows-SMB1Deprecation-Group-Package -Microsoft-Windows-SMB1Deprecation-Package -Microsoft-Windows-SMB1Server-D-Opt-Package -Microsoft-Windows-SearchEngine-Client-Package -Microsoft-Windows-SearchEngine-Client-Package-base-Package -Microsoft-Windows-SearchEngine-Client-Package-onecoreuap-Package -Microsoft-Windows-SearchEngine-Client-Package-shell-Package -Microsoft-Windows-SecConfig-Package -Microsoft-Windows-SecureStartup-Package -Microsoft-Windows-SecureStartup-Subsystem-Package -Microsoft-Windows-SecureStartup-Subsystem-WOW64-Package -Microsoft-Windows-Security-SPP-Component-SKU-Education-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-Enterprise-Default-Package -Microsoft-Windows-Security-SPP-Component-SKU-Enterprise-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-Enterprise-Package -Microsoft-Windows-Security-SPP-Component-SKU-IoTEnterprise-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-Professional-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-ProfessionalCountrySpecific-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-ProfessionalEducation-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-ProfessionalSingleLanguage-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-ProfessionalWorkstation-License-Package -Microsoft-Windows-Security-SPP-Component-SKU-ServerRdsh-License-Package -Microsoft-Windows-SenseClient-Package -Microsoft-Windows-ServicingStack-Base-Package -Microsoft-Windows-Shell32-OEMDefaultAssociations-Package -Microsoft-Windows-ShellExperienceHost-Package -Microsoft-Windows-SimpleTCP-Opt-Package -Microsoft-Windows-SimpleTCP-Package -Microsoft-Windows-SmbDirect-Opt-Package -Microsoft-Windows-SmbDirect-Package -Microsoft-Windows-Spelling-Dictionaries-de-Package -Microsoft-Windows-StepsRecorder-Package -Microsoft-Windows-StorageService-Package -Microsoft-Windows-TFTP-Client-Opt-Package -Microsoft-Windows-TFTP-Client-Package -Microsoft-Windows-TabShellExperience-Package -Microsoft-Windows-TabletPCMath-Package -Microsoft-Windows-Telnet-Client-Opt-Package -Microsoft-Windows-Telnet-Client-Package -Microsoft-Windows-TerminalServices-AppCompat-Opt-Package -Microsoft-Windows-TerminalServices-AppCompat-Opt-WOW64-Package -Microsoft-Windows-TerminalServices-AppServer-Client-Package -Microsoft-Windows-TerminalServices-AppServer-Client-WOW64-Package -Microsoft-Windows-TerminalServices-AppServerClient-Opt-Package -Microsoft-Windows-TerminalServices-AppServerClient-Opt-WOW64-Package -Microsoft-Windows-TerminalServices-CommandLineTools-Package -Microsoft-Windows-TerminalServices-Publishing-WMIProvider-Package -Microsoft-Windows-TerminalServices-RemoteApplications-Client-Package -Microsoft-Windows-TerminalServices-UsbRedirector-Package -Microsoft-Windows-TerminalServices-WMIProvider-Package -Microsoft-Windows-TextPrediction-Dictionaries-de-Package -Microsoft-Windows-UpdateTargeting-ClientOS-EKB-Package -Microsoft-Windows-UpdateTargeting-ClientOS-EKB-Wrapper-Package -Microsoft-Windows-UserExperience-Desktop-Package -Microsoft-Windows-Virtualization-RemoteFX-User-Mode-Transport-Package -Microsoft-Windows-Virtualization-RemoteFX-User-Mode-Transport-WOW64-Package -Microsoft-Windows-WMPNetworkSharingService-Opt-Package -Microsoft-Windows-WMPNetworkSharingService-Opt-WOW64-Package -Microsoft-Windows-WMPNetworkSharingService-Package -Microsoft-Windows-WMPNetworkSharingService-WOW64-Package -Microsoft-Windows-WPD-LegacyWmdmFeature-Feature-Package -Microsoft-Windows-WPD-LegacyWmdmFeature-Feature-WOW64-Package -Microsoft-Windows-WPD-UltimatePortableDeviceFeature-Feature-Package -Microsoft-Windows-WPD-UltimatePortableDeviceFeature-Feature-WOW64-Package -Microsoft-Windows-WebcamExperience-Package -Microsoft-Windows-WebcamExperience-WOW64-Package -Microsoft-Windows-WinOcr-Opt-Package -Microsoft-Windows-WinOcr-Package -Microsoft-Windows-WinSATMediaFiles-Package -Microsoft-Windows-WindowsFoundation-LanguagePack-Package -Microsoft-Windows-WindowsMediaPlayer-Troubleshooters-Package -Microsoft-Windows-WordPad-FoD-Package -Microsoft-Windows-WordPad-FoD-Package-Wrapper -Microsoft-Windows-msmq-adintegration-Opt-Package -Microsoft-Windows-msmq-dcomproxy-Opt-Package -Microsoft-Windows-msmq-dcomproxy-Opt-WOW64-Package -Microsoft-Windows-msmq-http-Opt-Package -Microsoft-Windows-msmq-http-Opt-WOW64-Package -Microsoft-Windows-msmq-mmc-Opt-Package -Microsoft-Windows-msmq-mmc-Opt-WOW64-Package -Microsoft-Windows-msmq-multicast-Opt-Package -Microsoft-Windows-msmq-powershell-Opt-Package -Microsoft-Windows-msmq-powershell-Opt-WOW64-Package -Microsoft-Windows-msmq-runtime-Opt-Package -Microsoft-Windows-msmq-runtime-Opt-WOW64-Package -Microsoft-Windows-msmq-server-Opt-Package -Microsoft-Windows-msmq-triggers-Opt-Package -Microsoft-Windows-msmq-triggers-Opt-WOW64-Package -MultiPoint-Connector-Opt-Package -MultiPoint-Help-Package -MultiPoint-Tools-Opt-Package -Multimedia-MFCore-Package -Multimedia-MFCore-WCOSHeadless-Package -Multimedia-MFCore-WCOSHeadless-WOW64-Package -Multimedia-MFCore-WCOSMinusHeadless-Package -Multimedia-MFCore-WCOSMinusHeadless-WOW64-Package -Multimedia-MFCore-WOW64-Package -Multimedia-RestrictedCodecsCore-Full-Package -Multimedia-RestrictedCodecsCore-Full-WOW64-Package -Multimedia-RestrictedCodecsCore-Package -Multimedia-RestrictedCodecsCore-WCOSHeadless-Package -Multimedia-RestrictedCodecsCore-WCOSHeadless-WOW64-Package -Multimedia-RestrictedCodecsCore-WCOSMinusHeadless-Package -Multimedia-RestrictedCodecsCore-WCOSMinusHeadless-WOW64-Package -Multimedia-RestrictedCodecsCore-WOW64-Package -Multimedia-RestrictedCodecsDolby-Package -Multimedia-RestrictedCodecsDolby-WOW64-Package -Multimedia-RestrictedCodecsExt-Package -Multimedia-RestrictedCodecsExt-WCOSHeadless-Package -Multimedia-RestrictedCodecsExt-WCOSHeadless-WOW64-Package -Multimedia-RestrictedCodecsExt-WCOSMinusHeadless-Package -Multimedia-RestrictedCodecsExt-WCOSMinusHeadless-WOW64-Package -Multimedia-RestrictedCodecsExt-WOW64-Package -Networking-MPSSVC-Rules-EnterpriseEdition-Package -OpenSSH-Client-Package -RemoteDesktopServices-Base-Package -Server-Help-Package.ClientEnterprise -Windows-Defender-AM-Default-Definitions-Package -Windows-Defender-AppLayer-Group-Package -Windows-Defender-ApplicationGuard-Inbox-Package -Windows-Defender-ApplicationGuard-Inbox-WOW64-Package -Windows-Defender-Client-Package -Windows-Defender-Core-Group-Package -Windows-Defender-Group-Policy-Package -Windows-Defender-Management-Group-Package -Windows-Defender-Management-MDM-Group-Package -Windows-Defender-Management-Powershell-Group-Package -Windows-Defender-Nis-Group-Package -WindowsSearchEngineSKU-Group-Package -microsoft-onecore-applicationmodel-sync-desktop-fod-package-Wrapper -microsoft-windows-RemoteFX-clientVM-RemoteFXWDDMDriver-WOW64-Package -microsoft-windows-notepad-fod-package-Wrapper -microsoft-windows-tabletpcmath-package-Wrapper -microsoft-windows-userexperience-desktop-package-Wrapper -openssh-client-package-Wrapper diff --git a/wimscripts/RunScriptTest.cmd b/wimscripts/RunScriptTest.cmd index fdf98a0..bd7b397 100644 --- a/wimscripts/RunScriptTest.cmd +++ b/wimscripts/RunScriptTest.cmd @@ -1,13 +1,15 @@ @echo off set SCRIPTS=%WINDIR%\Setup\scripts +set LOG=C:\SetupComplete.txt mkdir %SCRIPTS% 1>nul 2>nul +del /Q %LOG% echo ####### %0 ####### -copy /Y SetupComplete*.* %SCRIPTS% +copy /Y SetupComplete.cmd %SCRIPTS% echo ####### %0 ####### call %SCRIPTS%\SetupComplete.cmd -start notepad %SCRIPTS%\SetupComplete.txt +start notepad %LOG% diff --git a/wimscripts/SetupComplete.cmd b/wimscripts/SetupComplete.cmd index abe5eff..a5a8646 100644 --- a/wimscripts/SetupComplete.cmd +++ b/wimscripts/SetupComplete.cmd @@ -1,6 +1,7 @@ @echo off -set SCRIPTS=%WINDIR%\Setup\scripts -set LOG=%SCRIPTS%\SetupComplete.txt +set LOG=C:\SetupComplete.txt +set BATCH=SetupComplete.cmd +set PS1=SetupComplete.ps1 if not "%1"=="STDOUT_TO_FILE" %0 STDOUT_TO_FILE %* 1>%LOG% 2>&1 shift /1 @@ -8,12 +9,6 @@ shift /1 echo ####### %0 ####### date /t time /t - -echo DISABLE Windows "Hi" animation ... -@echo on -reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f -reg add "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System" /v EnableFirstLogonAnimation /t REG_DWORD /d 0 /f -@echo off echo. rem allow execution of any powershell script ... @@ -27,9 +22,25 @@ powershell -Command ^ }" echo. -rem call powershell stuff ... -powershell -Command %SCRIPTS%\SetupComplete.ps1 +rem try to call a script... +for %%D in (H G F E D) do ( + if EXIST %%D:\%PS1% ( + echo EXECUTING %PS1% on drive %%D ... + powershell -Command %%D:\%PS1% + ) else ( + echo INFO: %PS1% not found on drive %%D! + ) + if EXIST %%D:\%BATCH% ( + echo EXECUTING %BATCH% on drive %%D ... + call %%D:\%BATCH% + ) else ( + echo INFO: %BATCH% not found on drive %%D! + ) + +) + +echo. date /t time /t echo ####### %0 ####### diff --git a/wimscripts/SetupComplete.ps1 b/wimscripts/SetupComplete.ps1 deleted file mode 100644 index c4357bf..0000000 --- a/wimscripts/SetupComplete.ps1 +++ /dev/null @@ -1,10 +0,0 @@ -# REMOVE all applications except the Store... - -write-host '#######',(split-path $PSCommandPath -Leaf),'#######' - -$progressPreference = 'SilentlyContinue' -Get-AppxPackage -AllUsers | where-object {$_.name -notlike "*store*"} | Remove-AppxPackage -Get-AppxProvisionedPackage -online | where-object {$_.name -notlike "*store*"} | Remove-AppxProvisionedPackage -online - -write-host '#######',(split-path $PSCommandPath -Leaf),'#######' - diff --git a/wimscripts/export-image.cmd b/wimscripts/export-image.cmd index e6e0c60..a4b41d6 100644 --- a/wimscripts/export-image.cmd +++ b/wimscripts/export-image.cmd @@ -1,6 +1,6 @@ set SOURCES=c:\TEMP\Win10\sources -del %SOURCES%\install.wim 1>null 2>nul +del %SOURCES%\install.wim 1>nul 2>nul dism /Export-Image ^ /SourceImageFile:%SOURCES%\install.esd ^ diff --git a/wimscripts/finish-image.cmd b/wimscripts/finish-image.cmd index 9136014..aa37c84 100644 --- a/wimscripts/finish-image.cmd +++ b/wimscripts/finish-image.cmd @@ -1,10 +1,14 @@ -@set SOURCES=c:\TEMP\Win10\sources -@set MNT=c:\TEMP\WIM +@echo off +set SOURCES=c:\TEMP\Win10\sources +set MNT=c:\TEMP\WIM -@rd /S /Q %MNT%\Windows\Setup\scripts 1>nul 2>nul -@mkdir %MNT%\Windows\Setup\scripts 1>nul 2>nul -copy /Y SetupComplete*.cmd %MNT%\Windows\Setup\scripts -copy /Y SetupComplete*.ps1 %MNT%\Windows\Setup\scripts +rd /S /Q %MNT%\Windows\Setup\scripts 1>nul 2>nul +mkdir %MNT%\Windows\Setup\scripts 1>nul 2>nul + +rem copy SetupComplete script ... +copy /Y SetupComplete.cmd %MNT%\Windows\Setup\scripts +if %errorlevel% neq 0 exit /b %errorlevel% +dir %MNT%\Windows\Setup\scripts dism /Image:%MNT% /Cleanup-Image /StartComponentCleanup /ResetBase dism /Unmount-Wim /MountDir:%MNT% /Commit @@ -16,3 +20,5 @@ dism /Export-Image ^ /Compress:Recovery ^ /CheckIntegrity +rem del /Q %SOURCES%\install.wim + diff --git a/wimscripts/mount-wim.cmd b/wimscripts/mount-wim.cmd index 0f9ef2e..94b6efd 100644 --- a/wimscripts/mount-wim.cmd +++ b/wimscripts/mount-wim.cmd @@ -4,5 +4,3 @@ set MNT=c:\TEMP\WIM mkdir %MNT% dism /Mount-Wim /WimFile:%SOURCES%\install.wim /Name:"Windows 10 Pro" /MountDir:%MNT% -del null 1>nul 2>nul - diff --git a/wimscripts/remove-components.cmd b/wimscripts/remove-components.cmd deleted file mode 100644 index d97bb3a..0000000 --- a/wimscripts/remove-components.cmd +++ /dev/null @@ -1,167 +0,0 @@ -set MNT=c:\TEMP\WIM - -rem GROUP 1: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Internet" /r /n -install_wim_tweak.exe /p %MNT% /c "Adobe-Flash" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Cortana" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Search2" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-SearchEngine" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-RetailDemo" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-ContactSupport" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-PPIProjection" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Backup" /r /n -rem install_wim_tweak.exe /p %MNT% /c "Windows-Defender" /r /n - -rem GROUP 2: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Xbox" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-TroubleShooting" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-TroubleShooting" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-LanguageFeatures" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Legacy" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-SpeechComponents" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Gaming" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Indexer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-BioEnrollment" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Biometrics" /r /n - -rem GROUP 3: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Printing-XPSServices" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Xps" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Geolocation" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Compression" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-BusinessScanning" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MediaPlayer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WindowsMediaPlayer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-VirtualPC" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-VirtualXP" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-SystemRestore" /r /n - -rem GROUP 4: -install_wim_tweak.exe /p %MNT% /c "Server-Help" /r /n -install_wim_tweak.exe /p %MNT% /c "Sensors-Universal" /r /n -install_wim_tweak.exe /p %MNT% /c "MultiPoint-Help" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WordBreaking" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WorkplaceJoin" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WinSATMediaFiles" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WinOcr" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WebcamExperience" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Virtualization" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-TextPrediction" /r /n - -rem GROUP 5: -install_wim_tweak.exe /p %MNT% /c "HyperV" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Hyper" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-HyperV" /r /n -install_wim_tweak.exe /p %MNT% /c "Media-FaceAnalysis" /r /n -install_wim_tweak.exe /p %MNT% /c "Media-Ocr" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Mobile" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-AllJoyn" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-AllowTelemetry" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-BITS" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-CameraCaptureUI" /r /n - -rem GROUP 6: -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Connectivity-NFC" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Connectivity-Serial" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-DebugCore" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-InkPlatform" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Maps" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Miracast" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Multimedia-CastingCommon" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Multimedia-CastingReceiver" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Multimedia-CastingTransmitter" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-NowPlayingSessionManager" /r /n - -rem GROUP 7: -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-RemoteDesktopServices" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Sensors" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Tethering" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-UserDataAccess" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Wallet" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-WebService" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-3DAudio" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-AppCompat" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-BITS" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Browser" /r /n - -rem GROUP 8: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Casting" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-CoreSystem-DebugTransports" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Help" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WMIPerf" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-IIS-WebServer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Killbits" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Lxss" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Media-Streaming" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MiracastView" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MobilePC" /r /n - -rem GROUP 9: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Shell-HomeGroup" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Network-Connectivity-Assistant" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-QuickAssist" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-RemoteAssistance" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-RemoteFX" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-RemoteDesktop" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-TabletPC" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-SNMP" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Skype" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Shell-SettingSync" /r /n - -rem GROUP 10: -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-ApplicationModel-Sync" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-DeviceSync" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-EnterpriseClientSync" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-ShareMedia" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Telnet" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Serial" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-SenseClient" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-RDC" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Proximity" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Printing-PrintToPDFServices" /r /n - -rem GROUP 11: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-PerformanceCounters" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-PeerToPeer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-ParentalControls" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-OneDrive" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-OfflineFiles" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-NFS" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-NetworkDiagnostics" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Network-QoS" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MRT10" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MobileBroadband" /r /n - -rem GROUP 12: -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-EnergyEstimationEngine" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Networking-MobileBroadbandApi" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-PointOfService" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-ContentDeliveryManager" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-DataCenterBridging" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Links" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Migration" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-MobileCore" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-PeerDist" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-SnippingTool" /r /n - -rem GROUP 13: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Store" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Common-Modem" /r /n -install_wim_tweak.exe /p %MNT% /c "DeviceAccess" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-ESENT" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-InternetExplorer" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-OneCore-Multimedia-MFPMP" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-DirectoryServices-ADAM" /r /n -install_wim_tweak.exe /p %MNT% /c "microsoft-windows-directoryservices-adam" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-WinRT" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-International" /r /n - -rem GROUP 14: -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-TerminalServices" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-TS" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-Provisioning" /r /n -install_wim_tweak.exe /p %MNT% /c "Microsoft-Windows-LanguageEnablingComponents" /r /n - -rem CLEANUP: -del SOFTWAREBKP 1>nul 2>nul -