mirror of
https://github.com/Disassembler0/Win10-Initial-Setup-Script.git
synced 2026-01-09 14:08:05 -05:00
Minor changes (#133)
- shortened Default.cmd - prevented annoying homegroup errors for 1803+ (counterpart for enabling not touched, cuz it's good to see the errors in this case imo)
This commit is contained in:
committed by
Disassembler0
parent
1e977ab95f
commit
5fae7389e1
@@ -1,3 +1 @@
|
||||
@ECHO OFF
|
||||
|
||||
powershell.exe -NoProfile -ExecutionPolicy Bypass -File "%~dp0Win10.ps1" -include "%~dp0Win10.psm1" -preset "%~dpn0.preset"
|
||||
@powershell.exe -NoProfile -ExecutionPolicy Bypass -File "%~dp0Win10.ps1" -include "%~dp0Win10.psm1" -preset "%~dpn0.preset"
|
||||
|
||||
12
Win10.psm1
12
Win10.psm1
@@ -796,10 +796,14 @@ Function EnableUpdateRestart {
|
||||
# Stop and disable Home Groups services - Not applicable to 1803 and newer or Server
|
||||
Function DisableHomeGroups {
|
||||
Write-Output "Stopping and disabling Home Groups services..."
|
||||
Stop-Service "HomeGroupListener" -WarningAction SilentlyContinue
|
||||
Set-Service "HomeGroupListener" -StartupType Disabled
|
||||
Stop-Service "HomeGroupProvider" -WarningAction SilentlyContinue
|
||||
Set-Service "HomeGroupProvider" -StartupType Disabled
|
||||
If (Get-Service "HomeGroupListener" -ErrorAction SilentlyContinue) {
|
||||
Stop-Service "HomeGroupListener" -WarningAction SilentlyContinue
|
||||
Set-Service "HomeGroupListener" -StartupType Disabled
|
||||
}
|
||||
If (Get-Service "HomeGroupProvider" -ErrorAction SilentlyContinue) {
|
||||
Stop-Service "HomeGroupProvider" -WarningAction SilentlyContinue
|
||||
Set-Service "HomeGroupProvider" -StartupType Disabled
|
||||
}
|
||||
}
|
||||
|
||||
# Enable and start Home Groups services - Not applicable to 1803 and newer or Server
|
||||
|
||||
Reference in New Issue
Block a user