Ver Fonte

Added Function CheckInstallService

Richard Newton há 6 anos atrás
pai
commit
69246b9cc2
1 ficheiros alterados com 8 adições e 0 exclusões
  1. 8 0
      Windows10SysPrepDebloater.ps1

+ 8 - 0
Windows10SysPrepDebloater.ps1

@@ -209,6 +209,14 @@ Function CheckService {
         Start-Service -Name dmwappushservice }
 }
 
+Function CheckInstallService {
+
+  Param([switch]$Debloat)
+  
+  If (Get-Service -Name InstallService | Where-Object ($_.Status -eq "Stopped"}) {
+      Start-Service -Name InstallService
+      Set-Service -Name InstallService -StartupType Automatic
+
 Write-Output "Initiating Sysprep"
 Begin-SysPrep
 Write-Output "Removing bloatware apps."