Browse Source

Minor improvements and fixes

bumped versions
6.6.8
Dmitry Nefedov 5 months ago
parent
commit
4eaa58ea97
  1. 4
      Download_Sophia.ps1
  2. 128
      Wrapper/Config/config_Windows_10.json
  3. 108
      Wrapper/Config/config_Windows_10_LTSC.json
  4. 128
      Wrapper/Config/config_Windows_11.json
  5. 112
      Wrapper/Localizations/de-DE/tooltip_Windows_10.json
  6. 112
      Wrapper/Localizations/de-DE/tooltip_Windows_11.json
  7. 112
      Wrapper/Localizations/en-US/tooltip_Windows_10.json
  8. 112
      Wrapper/Localizations/en-US/tooltip_Windows_11.json
  9. 112
      Wrapper/Localizations/ru-RU/tooltip_Windows_10.json
  10. 112
      Wrapper/Localizations/ru-RU/tooltip_Windows_11.json
  11. 14
      sophia_script_versions.json
  12. 8
      src/Sophia_Script_for_Windows_10/Functions.ps1
  13. 4
      src/Sophia_Script_for_Windows_10/Manifest/Sophia.psd1
  14. 50
      src/Sophia_Script_for_Windows_10/Module/Sophia.psm1
  15. 76
      src/Sophia_Script_for_Windows_10/Sophia.ps1
  16. 8
      src/Sophia_Script_for_Windows_10_LTSC_2019/Functions.ps1
  17. 4
      src/Sophia_Script_for_Windows_10_LTSC_2019/Manifest/Sophia.psd1
  18. 43
      src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1
  19. 39
      src/Sophia_Script_for_Windows_10_LTSC_2019/Sophia.ps1
  20. 8
      src/Sophia_Script_for_Windows_10_LTSC_2021/Functions.ps1
  21. 4
      src/Sophia_Script_for_Windows_10_LTSC_2021/Manifest/Sophia.psd1
  22. 43
      src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1
  23. 56
      src/Sophia_Script_for_Windows_10_LTSC_2021/Sophia.ps1
  24. 8
      src/Sophia_Script_for_Windows_10_PowerShell_7/Functions.ps1
  25. 4
      src/Sophia_Script_for_Windows_10_PowerShell_7/Manifest/Sophia.psd1
  26. 50
      src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1
  27. 76
      src/Sophia_Script_for_Windows_10_PowerShell_7/Sophia.ps1
  28. 8
      src/Sophia_Script_for_Windows_11/Functions.ps1
  29. 4
      src/Sophia_Script_for_Windows_11/Manifest/Sophia.psd1
  30. 74
      src/Sophia_Script_for_Windows_11/Module/Sophia.psm1
  31. 72
      src/Sophia_Script_for_Windows_11/Sophia.ps1
  32. 8
      src/Sophia_Script_for_Windows_11_PowerShell_7/Functions.ps1
  33. 4
      src/Sophia_Script_for_Windows_11_PowerShell_7/Manifest/Sophia.psd1
  34. 60
      src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1
  35. 76
      src/Sophia_Script_for_Windows_11_PowerShell_7/Sophia.ps1

4
Download_Sophia.ps1

@ -38,7 +38,7 @@ switch ((Get-CimInstance -ClassName Win32_OperatingSystem).BuildNumber)
{ {
"17763" "17763"
{ {
# Check if Windows 10 is LTSC 2019 # Check for Windows 10 LTSC 2019
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ProductName) -match "LTSC 2019") if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ProductName) -match "LTSC 2019")
{ {
$LatestRelease = (Invoke-RestMethod @Parameters).Sophia_Script_Windows_10_LTSC2019 $LatestRelease = (Invoke-RestMethod @Parameters).Sophia_Script_Windows_10_LTSC2019
@ -69,7 +69,7 @@ switch ((Get-CimInstance -ClassName Win32_OperatingSystem).BuildNumber)
} }
"19044" "19044"
{ {
# Check if Windows 10 is LTSC 2021 # Check for Windows 10 LTSC 2021
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ProductName) -match "LTSC 2021") if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" -Name ProductName) -match "LTSC 2021")
{ {
$LatestRelease = (Invoke-RestMethod @Parameters).Sophia_Script_Windows_10_LTSC2021 $LatestRelease = (Invoke-RestMethod @Parameters).Sophia_Script_Windows_10_LTSC2021

128
Wrapper/Config/config_Windows_10.json

@ -1202,6 +1202,70 @@
"Preset": "Zero", "Preset": "Zero",
"WindowsDefault": "One" "WindowsDefault": "One"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable"
},
"One": {
"Tag": "Enable"
}
},
"Preset": "Zero",
"WindowsDefault": "Zero"
},
{ {
"Region": "System", "Region": "System",
"Control": "cmb", "Control": "cmb",
@ -1496,70 +1560,6 @@
"Preset": "Zero", "Preset": "Zero",
"WindowsDefault": "One" "WindowsDefault": "One"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable"
},
"One": {
"Tag": "Enable"
}
},
"Preset": "Zero",
"WindowsDefault": "Zero"
},
{ {
"Region": "System", "Region": "System",
"Control": "chk", "Control": "chk",

108
Wrapper/Config/config_Windows_10_LTSC.json

@ -1094,6 +1094,60 @@
"LTSC2019": "true", "LTSC2019": "true",
"LTSC2021": "true" "LTSC2021": "true"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "true",
"LTSC2021": "true"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "false",
"LTSC2021": "true"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "true",
"LTSC2021": "true"
},
{ {
"Region": "System", "Region": "System",
"Control": "cmb", "Control": "cmb",
@ -1422,60 +1476,6 @@
"LTSC2019": "true", "LTSC2019": "true",
"LTSC2021": "true" "LTSC2021": "true"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "true",
"LTSC2021": "true"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "false",
"LTSC2021": "true"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One",
"LTSC2019": "true",
"LTSC2021": "true"
},
{ {
"Region": "System", "Region": "System",
"Control": "chk", "Control": "chk",

128
Wrapper/Config/config_Windows_11.json

@ -1125,6 +1125,70 @@
"Preset": "Zero", "Preset": "Zero",
"WindowsDefault": "One" "WindowsDefault": "One"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable"
},
"One": {
"Tag": "Enable"
}
},
"Preset": "Zero",
"WindowsDefault": "Zero"
},
{ {
"Region": "System", "Region": "System",
"Control": "cmb", "Control": "cmb",
@ -1419,70 +1483,6 @@
"Preset": "Zero", "Preset": "Zero",
"WindowsDefault": "One" "WindowsDefault": "One"
}, },
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show"
},
"One": {
"Tag": "Hide"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable"
},
"One": {
"Tag": "Disable"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically"
},
"One": {
"Tag": "Manually"
}
},
"Preset": "Zero",
"WindowsDefault": "One"
},
{
"Region": "System",
"Control": "cmb",
"Required": "false",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable"
},
"One": {
"Tag": "Enable"
}
},
"Preset": "Zero",
"WindowsDefault": "Zero"
},
{ {
"Region": "System", "Region": "System",
"Control": "chk", "Control": "chk",

112
Wrapper/Localizations/de-DE/tooltip_Windows_10.json

@ -1054,6 +1054,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Eine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen."
},
"One": {
"Tag": "Hide",
"ToolTip": "Keine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Starten Sie das Gerät so bald wie möglich neu, wenn ein Neustart erforderlich ist, um ein Update zu installieren."
},
"One": {
"Tag": "Disable",
"ToolTip": "Dieses Gerät nicht so schnell wie möglich neu starten, wenn ein Neustart erforderlich ist, um ein Update zu installieren (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatische Anpassung der aktiven Stunden auf der Grundlage der täglichen Nutzung."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manuelle Anpassung der aktiven Stunden für mich auf der Grundlage der täglichen Nutzung (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Holen Sie sich keine Windows-Updates, sobald sie für Ihr Gerät verfügbar sind (Standardeinstellung)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Holen Sie sich Windows-Updates, sobald sie für Ihr Gerät verfügbar sind."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1314,62 +1370,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Eine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen."
},
"One": {
"Tag": "Hide",
"ToolTip": "Keine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Starten Sie das Gerät so bald wie möglich neu, wenn ein Neustart erforderlich ist, um ein Update zu installieren."
},
"One": {
"Tag": "Disable",
"ToolTip": "Dieses Gerät nicht so schnell wie möglich neu starten, wenn ein Neustart erforderlich ist, um ein Update zu installieren (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatische Anpassung der aktiven Stunden auf der Grundlage der täglichen Nutzung."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manuelle Anpassung der aktiven Stunden für mich auf der Grundlage der täglichen Nutzung (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Holen Sie sich keine Windows-Updates, sobald sie für Ihr Gerät verfügbar sind (Standardeinstellung)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Holen Sie sich Windows-Updates, sobald sie für Ihr Gerät verfügbar sind."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

112
Wrapper/Localizations/de-DE/tooltip_Windows_11.json

@ -988,6 +988,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Eine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen."
},
"One": {
"Tag": "Hide",
"ToolTip": "Keine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Starten Sie das Gerät so bald wie möglich neu, wenn ein Neustart erforderlich ist, um ein Update zu installieren."
},
"One": {
"Tag": "Disable",
"ToolTip": "Dieses Gerät nicht so schnell wie möglich neu starten, wenn ein Neustart erforderlich ist, um ein Update zu installieren (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatische Anpassung der aktiven Stunden auf der Grundlage der täglichen Nutzung."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manuelle Anpassung der aktiven Stunden für mich auf der Grundlage der täglichen Nutzung (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Holen Sie sich keine Windows-Updates, sobald sie für Ihr Gerät verfügbar sind (Standardeinstellung)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Holen Sie sich Windows-Updates, sobald sie für Ihr Gerät verfügbar sind."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1248,62 +1304,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Eine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen."
},
"One": {
"Tag": "Hide",
"ToolTip": "Keine Benachrichtigung anzeigen, wenn Ihr PC neu gestartet werden muss, um die Aktualisierung abzuschließen (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Starten Sie das Gerät so bald wie möglich neu, wenn ein Neustart erforderlich ist, um ein Update zu installieren."
},
"One": {
"Tag": "Disable",
"ToolTip": "Dieses Gerät nicht so schnell wie möglich neu starten, wenn ein Neustart erforderlich ist, um ein Update zu installieren (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatische Anpassung der aktiven Stunden auf der Grundlage der täglichen Nutzung."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manuelle Anpassung der aktiven Stunden für mich auf der Grundlage der täglichen Nutzung (Standardeinstellung)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Holen Sie sich keine Windows-Updates, sobald sie für Ihr Gerät verfügbar sind (Standardeinstellung)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Holen Sie sich Windows-Updates, sobald sie für Ihr Gerät verfügbar sind."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

112
Wrapper/Localizations/en-US/tooltip_Windows_10.json

@ -1054,6 +1054,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Show a notification when your PC requires a restart to finish updating."
},
"One": {
"Tag": "Hide",
"ToolTip": "Do not show a notification when your PC requires a restart to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Restart this device as soon as possible when a restart is required to install an update."
},
"One": {
"Tag": "Disable",
"ToolTip": "Do not restart this device as soon as possible when a restart is required to install an update (default value)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatically adjust active hours for me based on daily usage."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manually adjust active hours for me based on daily usage (default value)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Do not get Windows updates as soon as they're available for your device (default value)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Get Windows updates as soon as they're available for your device."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1314,62 +1370,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Show a notification when your PC requires a restart to finish updating."
},
"One": {
"Tag": "Hide",
"ToolTip": "Do not show a notification when your PC requires a restart to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Restart this device as soon as possible when a restart is required to install an update."
},
"One": {
"Tag": "Disable",
"ToolTip": "Do not restart this device as soon as possible when a restart is required to install an update (default value)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatically adjust active hours for me based on daily usage."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manually adjust active hours for me based on daily usage (default value)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Do not get Windows updates as soon as they're available for your device (default value)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Get Windows updates as soon as they're available for your device."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

112
Wrapper/Localizations/en-US/tooltip_Windows_11.json

@ -988,6 +988,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Notify me when a restart is required to finish updating."
},
"One": {
"Tag": "Hide",
"ToolTip": "Do not notify me when a restart is required to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Restart as soon as possible to finish updating."
},
"One": {
"Tag": "Disable",
"ToolTip": "Don't restart as soon as possible to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatically adjust active hours for me based on daily usage."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manually adjust active hours for me based on daily usage (default value)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Do not get the latest updates as soon as they're available (default value)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Get the latest updates as soon as they're available."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1248,62 +1304,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Notify me when a restart is required to finish updating."
},
"One": {
"Tag": "Hide",
"ToolTip": "Do not notify me when a restart is required to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Restart as soon as possible to finish updating."
},
"One": {
"Tag": "Disable",
"ToolTip": "Don't restart as soon as possible to finish updating (default value)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Automatically adjust active hours for me based on daily usage."
},
"One": {
"Tag": "Manually",
"ToolTip": "Manually adjust active hours for me based on daily usage (default value)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Do not get the latest updates as soon as they're available (default value)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Get the latest updates as soon as they're available."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

112
Wrapper/Localizations/ru-RU/tooltip_Windows_10.json

@ -1054,6 +1054,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления."
},
"One": {
"Tag": "Hide",
"ToolTip": "Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка."
},
"One": {
"Tag": "Disable",
"ToolTip": "Не перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Автоматически изменять период активности для этого устройства на основе действий."
},
"One": {
"Tag": "Manually",
"ToolTip": "Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Не получать последние обновления, как только они будут доступны (значение по умолчанию)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Получайте последние обновления, как только они будут доступны."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1314,62 +1370,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления."
},
"One": {
"Tag": "Hide",
"ToolTip": "Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка."
},
"One": {
"Tag": "Disable",
"ToolTip": "Не перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Автоматически изменять период активности для этого устройства на основе действий."
},
"One": {
"Tag": "Manually",
"ToolTip": "Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Не получать последние обновления, как только они будут доступны (значение по умолчанию)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Получайте последние обновления, как только они будут доступны."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

112
Wrapper/Localizations/ru-RU/tooltip_Windows_11.json

@ -988,6 +988,62 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Уведомлять меня о необходимости перезагрузки для завершения обновления."
},
"One": {
"Tag": "Hide",
"ToolTip": "Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Перезапустить устройство как можно быстрее, чтобы завершить обновление."
},
"One": {
"Tag": "Disable",
"ToolTip": "Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Автоматически изменять период активности для этого устройства на основе действий."
},
"One": {
"Tag": "Manually",
"ToolTip": "Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Не получать последние обновления, как только они будут доступны (значение по умолчанию)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Получайте последние обновления, как только они будут доступны."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "PowerPlan", "Function": "PowerPlan",
@ -1248,62 +1304,6 @@
} }
} }
}, },
{
"Region": "System",
"Function": "RestartNotification",
"Arg": {
"Zero": {
"Tag": "Show",
"ToolTip": "Уведомлять меня о необходимости перезагрузки для завершения обновления."
},
"One": {
"Tag": "Hide",
"ToolTip": "Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "RestartDeviceAfterUpdate",
"Arg": {
"Zero": {
"Tag": "Enable",
"ToolTip": "Перезапустить устройство как можно быстрее, чтобы завершить обновление."
},
"One": {
"Tag": "Disable",
"ToolTip": "Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "ActiveHours",
"Arg": {
"Zero": {
"Tag": "Automatically",
"ToolTip": "Автоматически изменять период активности для этого устройства на основе действий."
},
"One": {
"Tag": "Manually",
"ToolTip": "Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)."
}
}
},
{
"Region": "System",
"Function": "WindowsLatestUpdate",
"Arg": {
"Zero": {
"Tag": "Disable",
"ToolTip": "Не получать последние обновления, как только они будут доступны (значение по умолчанию)."
},
"One": {
"Tag": "Enable",
"ToolTip": "Получайте последние обновления, как только они будут доступны."
}
}
},
{ {
"Region": "System", "Region": "System",
"Function": "Set-Association", "Function": "Set-Association",

14
sophia_script_versions.json

@ -1,10 +1,10 @@
{ {
"Sophia_Script_Windows_10_PowerShell_5_1": "5.18.7", "Sophia_Script_Windows_10_PowerShell_5_1": "5.18.8",
"Sophia_Script_Windows_10_PowerShell_7": "5.18.7", "Sophia_Script_Windows_10_PowerShell_7": "5.18.8",
"Sophia_Script_Windows_10_LTSC2019": "5.8.7", "Sophia_Script_Windows_10_LTSC2019": "5.8.8",
"Sophia_Script_Windows_10_LTSC2021": "5.18.7", "Sophia_Script_Windows_10_LTSC2021": "5.18.8",
"Sophia_Script_Windows_11_PowerShell_5_1": "6.6.7", "Sophia_Script_Windows_11_PowerShell_5_1": "6.6.8",
"Sophia_Script_Windows_11_LTSC2024": "6.6.7", "Sophia_Script_Windows_11_LTSC2024": "6.6.8",
"Sophia_Script_Windows_11_PowerShell_7": "6.6.7", "Sophia_Script_Windows_11_PowerShell_7": "6.6.8",
"Sophia_Script_Wrapper": "2.7.1" "Sophia_Script_Wrapper": "2.7.1"
} }

8
src/Sophia_Script_for_Windows_10/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_10/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '5.18.7' ModuleVersion = '5.18.8'
GUID = '109cc881-c42b-45af-a74a-550781989d6a' GUID = '109cc881-c42b-45af-a74a-550781989d6a'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '5.1' PowerShellVersion = '5.1'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

50
src/Sophia_Script_for_Windows_10/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -1005,7 +1005,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -1019,7 +1019,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1227,7 +1227,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -7205,7 +7205,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7961,6 +7962,7 @@ function WinPrtScrFolder
$UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore $UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore
if ($UserEmail) if ($UserEmail)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
@ -8908,9 +8910,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -9934,6 +9940,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -11097,6 +11104,9 @@ function UninstallUWPApps
#region Variables #region Variables
# The following UWP apps will have their checkboxes unchecked # The following UWP apps will have their checkboxes unchecked
$UncheckedAppxPackages = @( $UncheckedAppxPackages = @(
# Dolby Access
"DolbyLaboratories.DolbyAccess",
# Windows Media Player # Windows Media Player
"Microsoft.ZuneMusic", "Microsoft.ZuneMusic",
@ -12156,10 +12166,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12590,10 +12604,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12898,10 +12916,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -13695,10 +13717,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }
@ -13755,6 +13778,9 @@ function WindowsSandbox
if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")})) if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")}))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }

76
src/Sophia_Script_for_Windows_10/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 10" Default preset file for "Sophia Script for Windows 10"
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -69,7 +69,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -726,6 +726,38 @@ UpdateMicrosoftProducts -Enable
# При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию) # При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -931,38 +963,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Show a notification when your PC requires a restart to finish updating
# Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления
RestartNotification -Show
# Do not show a notification when your PC requires a restart to finish updating (default value)
# Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart this device as soon as possible when a restart is required to install an update
# Перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка
RestartDeviceAfterUpdate -Enable
# Do not restart this device as soon as possible when a restart is required to install an update (default value)
# Не перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get Windows updates as soon as they're available for your device (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get Windows updates as soon as they're available for your device
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"
@ -1095,6 +1095,10 @@ PinToStart -Tiles ControlPanel, DevicesPrinters
#endregion Start menu #endregion Start menu
#region UWP apps #region UWP apps
# Uninstall UWP apps using the pop-up dialog box
# Удалить UWP-приложения, используя всплывающее диалоговое окно
UninstallUWPApps
<# <#
Uninstall UWP apps for all users using the pop-up dialog box Uninstall UWP apps for all users using the pop-up dialog box
If the "For All Users" is checked apps packages will not be installed for new users If the "For All Users" is checked apps packages will not be installed for new users

8
src/Sophia_Script_for_Windows_10_LTSC_2019/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v5.8.7 Version: v5.8.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows 10 | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows 10 | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_10_LTSC_2019/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '5.8.7' ModuleVersion = '5.8.8'
GUID = 'a36a65ca-70f9-43df-856c-3048fc5e7f01' GUID = 'a36a65ca-70f9-43df-856c-3048fc5e7f01'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '5.1' PowerShellVersion = '5.1'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

43
src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.8.7 Version: v5.8.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -975,7 +975,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -989,7 +989,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1194,7 +1194,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -5852,7 +5852,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7207,9 +7208,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -8233,6 +8238,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -9010,10 +9016,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -9444,10 +9454,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -9752,10 +9766,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -10549,10 +10567,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }

39
src/Sophia_Script_for_Windows_10_LTSC_2019/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 10 LTSC 2019" Default preset file for "Sophia Script for Windows 10 LTSC 2019"
Version: v5.8.7 Version: v5.8.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -69,7 +69,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -567,6 +567,21 @@ UpdateMicrosoftProducts -Enable
# При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию) # При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -731,22 +746,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Show a notification when your PC requires a restart to finish updating
# Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления
RestartNotification -Show
# Do not show a notification when your PC requires a restart to finish updating (default value)
# Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"

8
src/Sophia_Script_for_Windows_10_LTSC_2021/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_10_LTSC_2021/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '5.18.7' ModuleVersion = '5.18.8'
GUID = '109cc881-c42b-45af-a74a-550781989d6a' GUID = '109cc881-c42b-45af-a74a-550781989d6a'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '5.1' PowerShellVersion = '5.1'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

43
src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -975,7 +975,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -989,7 +989,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1194,7 +1194,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -6244,7 +6244,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7838,9 +7839,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -8864,6 +8869,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -10144,10 +10150,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -10578,10 +10588,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -10886,10 +10900,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -11683,10 +11701,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }

56
src/Sophia_Script_for_Windows_10_LTSC_2021/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 10 LTSC 2021" Default preset file for "Sophia Script for Windows 10 LTSC 2021"
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -69,7 +69,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -623,6 +623,30 @@ UpdateMicrosoftProducts -Enable
# При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию) # При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -821,30 +845,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Show a notification when your PC requires a restart to finish updating
# Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления
RestartNotification -Show
# Do not show a notification when your PC requires a restart to finish updating (default value)
# Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart this device as soon as possible when a restart is required to install an update
# Перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка
RestartDeviceAfterUpdate -Enable
# Do not restart this device as soon as possible when a restart is required to install an update (default value)
# Не перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"

8
src/Sophia_Script_for_Windows_10_PowerShell_7/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.7 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.8 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_10_PowerShell_7/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '5.18.7' ModuleVersion = '5.18.8'
GUID = 'aa0b47a7-1770-4b5d-8c9f-cc6c505bcc7a' GUID = 'aa0b47a7-1770-4b5d-8c9f-cc6c505bcc7a'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '7.3' PowerShellVersion = '7.3'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

50
src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -1009,7 +1009,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -1023,7 +1023,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1231,7 +1231,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -7211,7 +7211,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7967,6 +7968,7 @@ function WinPrtScrFolder
$UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore $UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore
if ($UserEmail) if ($UserEmail)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
@ -8914,9 +8916,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034763 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -9940,6 +9946,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -11113,6 +11120,9 @@ function UninstallUWPApps
#region Variables #region Variables
# The following UWP apps will have their checkboxes unchecked # The following UWP apps will have their checkboxes unchecked
$UncheckedAppxPackages = @( $UncheckedAppxPackages = @(
# Dolby Access
"DolbyLaboratories.DolbyAccess",
# Windows Media Player # Windows Media Player
"Microsoft.ZuneMusic", "Microsoft.ZuneMusic",
@ -12172,10 +12182,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12606,10 +12620,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12914,10 +12932,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -13711,10 +13733,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }
@ -13771,6 +13794,9 @@ function WindowsSandbox
if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")})) if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")}))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }

76
src/Sophia_Script_for_Windows_10_PowerShell_7/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 10 (PowerShell 7)" Default preset file for "Sophia Script for Windows 10 (PowerShell 7)"
Version: v5.18.7 Version: v5.18.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -69,7 +69,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.7 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.8 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
@ -737,6 +737,38 @@ UpdateMicrosoftProducts -Enable
# При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию) # При обновлении Windows не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -942,38 +974,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Show a notification when your PC requires a restart to finish updating
# Показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления
RestartNotification -Show
# Do not show a notification when your PC requires a restart to finish updating (default value)
# Не показывать уведомление, когда компьютеру требуется перезагрузка для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart this device as soon as possible when a restart is required to install an update
# Перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка
RestartDeviceAfterUpdate -Enable
# Do not restart this device as soon as possible when a restart is required to install an update (default value)
# Не перезапускать это устройство как можно быстрее, если для установки обновления требуется перезагрузка (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get Windows updates as soon as they're available for your device (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get Windows updates as soon as they're available for your device
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"
@ -1106,6 +1106,10 @@ PinToStart -Tiles ControlPanel, DevicesPrinters
#endregion Start menu #endregion Start menu
#region UWP apps #region UWP apps
# Uninstall UWP apps using the pop-up dialog box
# Удалить UWP-приложения, используя всплывающее диалоговое окно
UninstallUWPApps
<# <#
Uninstall UWP apps for all users using the pop-up dialog box Uninstall UWP apps for all users using the pop-up dialog box
If the "For All Users" is checked apps packages will not be installed for new users If the "For All Users" is checked apps packages will not be installed for new users

8
src/Sophia_Script_for_Windows_11/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_11/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '6.6.7' ModuleVersion = '6.6.8'
GUID = '109cc881-c42b-45af-a74a-550781989d6a' GUID = '109cc881-c42b-45af-a74a-550781989d6a'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '5.1' PowerShellVersion = '5.1'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

74
src/Sophia_Script_for_Windows_11/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -594,20 +594,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
exit exit
} }
if ((Get-WindowsEdition -Online).Edition -match "EnterpriseS")
{
# Will be removed when Windows 11 Enterprise LTSC will be released officially this Autumn along side with 24H2
Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message "You're using a leaked Windows 11 Enterprise LTSC image. The official release set to November."
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
Write-Verbose -Message "https://discord.gg/sSryhaEv79" -Verbose
Write-Verbose -Message "https://github.com/farag2/Sophia-Script-for-Windows#system-requirements" -Verbose
exit
}
# Detect Windows build version # Detect Windows build version
switch ((Get-CimInstance -ClassName CIM_OperatingSystem).BuildNumber) switch ((Get-CimInstance -ClassName CIM_OperatingSystem).BuildNumber)
{ {
@ -993,7 +979,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -1007,7 +993,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1215,7 +1201,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -7008,7 +6994,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7764,6 +7751,7 @@ function WinPrtScrFolder
$UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore $UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore
if ($UserEmail) if ($UserEmail)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
@ -8507,9 +8495,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034765 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034765 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -9533,6 +9525,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -10436,6 +10429,9 @@ function UninstallUWPApps
#region Variables #region Variables
# The following UWP apps will have their checkboxes unchecked # The following UWP apps will have their checkboxes unchecked
$UncheckedAppxPackages = @( $UncheckedAppxPackages = @(
# Dolby Access
"DolbyLaboratories.DolbyAccess",
# Windows Media Player # Windows Media Player
"Microsoft.ZuneMusic", "Microsoft.ZuneMusic",
@ -11329,10 +11325,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -11763,10 +11763,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12071,10 +12075,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12866,10 +12874,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }
@ -12926,6 +12935,9 @@ function WindowsSandbox
if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")})) if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")}))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13392,6 +13404,9 @@ function EditWithClipchampContext
if (-not (Get-AppxPackage -Name Clipchamp.Clipchamp)) if (-not (Get-AppxPackage -Name Clipchamp.Clipchamp))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13676,6 +13691,9 @@ function OpenWindowsTerminalContext
if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal)) if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13738,6 +13756,9 @@ function OpenWindowsTerminalAdminContext
if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal)) if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13754,6 +13775,7 @@ function OpenWindowsTerminalAdminContext
} }
catch [System.ArgumentException] catch [System.ArgumentException]
{ {
Write-Warning -Message ($Global:Error.Exception.Message | Select-Object -First 1)
Write-Error -Message ($Global:Error.Exception.Message | Select-Object -First 1) -ErrorAction SilentlyContinue Write-Error -Message ($Global:Error.Exception.Message | Select-Object -First 1) -ErrorAction SilentlyContinue
Invoke-Item -Path "$env:LOCALAPPDATA\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState" Invoke-Item -Path "$env:LOCALAPPDATA\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState"

72
src/Sophia_Script_for_Windows_11/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 11" Default preset file for "Sophia Script for Windows 11"
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -68,7 +68,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -701,6 +701,38 @@ UpdateMicrosoftProducts -Enable
# Не получать обновления для других продуктов Майкрософт (значение по умолчанию) # Не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -906,38 +938,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"

8
src/Sophia_Script_for_Windows_11_PowerShell_7/Functions.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
The TAB completion for functions and their arguments The TAB completion for functions and their arguments
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -49,7 +49,7 @@ function Sophia
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.7 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.8 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

4
src/Sophia_Script_for_Windows_11_PowerShell_7/Manifest/Sophia.psd1

@ -1,9 +1,9 @@
@{ @{
RootModule = '..\Module\Sophia.psm1' RootModule = '..\Module\Sophia.psm1'
ModuleVersion = '6.6.7' ModuleVersion = '6.6.8'
GUID = '109cc881-c42b-45af-a74a-550781989d6a' GUID = '109cc881-c42b-45af-a74a-550781989d6a'
Author = 'Dmitry "farag" Nefedov' Author = 'Dmitry "farag" Nefedov'
Copyright = '(c) 2014—2024 farag, Inestic & lowl1f3. All rights reserved' Copyright = '(c) 2014—2025 farag, Inestic & lowl1f3. All rights reserved'
Description = 'Module for Windows fine-tuning and automating the routine tasks' Description = 'Module for Windows fine-tuning and automating the routine tasks'
PowerShellVersion = '7.3' PowerShellVersion = '7.3'
ProcessorArchitecture = 'AMD64' ProcessorArchitecture = 'AMD64'

60
src/Sophia_Script_for_Windows_11_PowerShell_7/Module/Sophia.psm1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -997,7 +997,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
[string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")} [string]$PresetName = ((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}
Write-Verbose -Message ($Localization.CustomizationWarning -f $PresetName) -Verbose Write-Verbose -Message ($Localization.CustomizationWarning -f "`"$PresetName`"") -Verbose
do do
{ {
@ -1011,7 +1011,7 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
} }
$No $No
{ {
Invoke-Item -Path $PSScriptRoot\..\$PresetName Invoke-Item -Path $PresetName
Start-Sleep -Seconds 5 Start-Sleep -Seconds 5
@ -1219,7 +1219,7 @@ function DiagTrackService
# $_.File has no EndsWith() method # $_.File has no EndsWith() method
$PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf $PresetName = Split-Path -Path (((Get-PSCallStack).Position | Where-Object -FilterScript {$_.File}).File | Where-Object -FilterScript {$_.EndsWith(".ps1")}) -Leaf
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f $PresetName) -Verbose Write-Verbose -Message ($Localization.InitialActionsCheckFailed -f "`"$PresetName`"") -Verbose
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message "https://t.me/sophia_chat" -Verbose Write-Verbose -Message "https://t.me/sophia_chat" -Verbose
@ -7014,7 +7014,8 @@ public extern static int SHSetKnownFolderPath(ref Guid folderId, uint flags, Int
if (-not $DriveLetters) if (-not $DriveLetters)
{ {
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserFolderLocationMove -Verbose Write-Warning -Message $Localization.UserFolderLocationMove
Write-Error -Message $Localization.UserFolderLocationMove -ErrorAction SilentlyContinue
return return
} }
@ -7770,6 +7771,7 @@ function WinPrtScrFolder
$UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore $UserEmail = Get-ItemProperty -Path HKCU:\Software\Microsoft\OneDrive\Accounts\Personal -Name UserEmail -ErrorAction Ignore
if ($UserEmail) if ($UserEmail)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) Write-Warning -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.OneDriveWarning -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
@ -8513,9 +8515,13 @@ function Set-Association
# Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034765 release # Microsoft blocked ability to write to UserChoice key for .pdf extention and http and https protocols with KB5034765 release
if (@(".pdf", "http", "https") -contains $Extension) if (@(".pdf", "http", "https") -contains $Extension)
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.UserChoiceWarning -Verbose Write-Verbose -Message $Localization.UserChoiceWarning -Verbose
Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue Write-Error -Message $Localization.UserChoiceWarning -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -9539,6 +9545,7 @@ function Import-Associations
} }
catch [System.Exception] catch [System.Exception]
{ {
Write-Warning -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim())
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue Write-Information -MessageData "" -InformationAction Continue
@ -10452,6 +10459,9 @@ function UninstallUWPApps
#region Variables #region Variables
# The following UWP apps will have their checkboxes unchecked # The following UWP apps will have their checkboxes unchecked
$UncheckedAppxPackages = @( $UncheckedAppxPackages = @(
# Dolby Access
"DolbyLaboratories.DolbyAccess",
# Windows Media Player # Windows Media Player
"Microsoft.ZuneMusic", "Microsoft.ZuneMusic",
@ -11345,10 +11355,14 @@ function CleanupTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -11779,10 +11793,14 @@ function SoftwareDistributionTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12087,10 +12105,14 @@ function TempTask
if ($TaskUserAccount -ne $env:USERNAME) if ($TaskUserAccount -ne $env:USERNAME)
{ {
Write-Verbose -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -Verbose Write-Information -MessageData "" -InformationAction Continue
Write-Warning -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount)
Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.ScheduledTaskPresented -f $MyInvocation.Line.Trim(), $TaskUserAccount) -ErrorAction SilentlyContinue
Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue Write-Error -Message ($Localization.RestartFunction -f $MyInvocation.Line.Trim()) -ErrorAction SilentlyContinue
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
} }
@ -12882,10 +12904,11 @@ function WindowsScriptHost
"Disable" "Disable"
{ {
# Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files # Check if any scheduled tasks were created before, because they rely on Windows Host running vbs files
Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" | ForEach-Object -Process { Get-ScheduledTask -TaskName SoftwareDistribution, Temp, "Windows Cleanup", "Windows Cleanup Notification" -ErrorAction Ignore | ForEach-Object -Process {
# Skip if a scheduled task exists
if ($_.State -eq "Ready") if ($_.State -eq "Ready")
{ {
continue break
} }
} }
@ -12942,6 +12965,9 @@ function WindowsSandbox
if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")})) if (-not (Get-WindowsEdition -Online | Where-Object -FilterScript {($_.Edition -eq "Professional") -or ($_.Edition -eq "Enterprise") -or ($_.Edition -eq "Education")}))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13408,6 +13434,9 @@ function EditWithClipchampContext
if (-not (Get-AppxPackage -Name Clipchamp.Clipchamp)) if (-not (Get-AppxPackage -Name Clipchamp.Clipchamp))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13692,6 +13721,9 @@ function OpenWindowsTerminalContext
if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal)) if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13754,6 +13786,9 @@ function OpenWindowsTerminalAdminContext
if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal)) if (-not (Get-AppxPackage -Name Microsoft.WindowsTerminal))
{ {
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return return
} }
@ -13770,6 +13805,7 @@ function OpenWindowsTerminalAdminContext
} }
catch [System.ArgumentException] catch [System.ArgumentException]
{ {
Write-Warning -Message ($Global:Error.Exception.Message | Select-Object -First 1)
Write-Error -Message ($Global:Error.Exception.Message | Select-Object -First 1) -ErrorAction SilentlyContinue Write-Error -Message ($Global:Error.Exception.Message | Select-Object -First 1) -ErrorAction SilentlyContinue
Invoke-Item -Path "$env:LOCALAPPDATA\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState" Invoke-Item -Path "$env:LOCALAPPDATA\Packages\Microsoft.WindowsTerminal_8wekyb3d8bbwe\LocalState"

76
src/Sophia_Script_for_Windows_11_PowerShell_7/Sophia.ps1

@ -2,10 +2,10 @@
.SYNOPSIS .SYNOPSIS
Default preset file for "Sophia Script for Windows 11 (PowerShell 7)" Default preset file for "Sophia Script for Windows 11 (PowerShell 7)"
Version: v6.6.7 Version: v6.6.8
Date: 12.05.2024 Date: 06.07.2025
Copyright (c) 20142024 farag, Inestic & lowl1f3 Copyright (c) 20142025 farag, Inestic & lowl1f3
Thanks to all https://forum.ru-board.com members involved Thanks to all https://forum.ru-board.com members involved
@ -68,7 +68,7 @@ param
Clear-Host Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.7 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2024" $Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.8 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag, Inestic & lowl1f3, 2014$([System.Char]0x2013)2025"
Remove-Module -Name Sophia -Force -ErrorAction Ignore Remove-Module -Name Sophia -Force -ErrorAction Ignore
@ -712,6 +712,38 @@ UpdateMicrosoftProducts -Enable
# Не получать обновления для других продуктов Майкрософт (значение по умолчанию) # Не получать обновления для других продуктов Майкрософт (значение по умолчанию)
# UpdateMicrosoftProducts -Disable # UpdateMicrosoftProducts -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
# Set power plan on "High performance". It isn't recommended to turn on for laptops # Set power plan on "High performance". It isn't recommended to turn on for laptops
# Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках # Установить схему управления питанием на "Высокая производительность". Не рекомендуется включать на ноутбуках
PowerPlan -High PowerPlan -High
@ -917,38 +949,6 @@ NetworkDiscovery -Enable
# Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию) # Выключить сетевое обнаружение и общий доступ к файлам и принтерам для рабочих групп (значение по умолчанию)
# NetworkDiscovery -Disable # NetworkDiscovery -Disable
# Notify me when a restart is required to finish updating
# Уведомлять меня о необходимости перезагрузки для завершения обновления
RestartNotification -Show
# Do not notify me when a restart is required to finish updating (default value)
# Не yведомлять меня о необходимости перезагрузки для завершения обновления (значение по умолчанию)
# RestartNotification -Hide
# Restart as soon as possible to finish updating
# Перезапустить устройство как можно быстрее, чтобы завершить обновление
RestartDeviceAfterUpdate -Enable
# Don't restart as soon as possible to finish updating (default value)
# Не перезапускать устройство как можно быстрее, чтобы завершить обновление (значение по умолчанию)
# RestartDeviceAfterUpdate -Disable
# Automatically adjust active hours for me based on daily usage
# Автоматически изменять период активности для этого устройства на основе действий
ActiveHours -Automatically
# Manually adjust active hours for me based on daily usage (default value)
# Вручную изменять период активности для этого устройства на основе действий (значение по умолчанию)
# ActiveHours -Manually
# Do not get the latest updates as soon as they're available (default value)
# Не получать последние обновления, как только они будут доступны (значение по умолчанию)
WindowsLatestUpdate -Disable
# Get the latest updates as soon as they're available
# Получайте последние обновления, как только они будут доступны
# WindowsLatestUpdate -Enable
<# <#
Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden Register app, calculate hash, and associate with an extension with the "How do you want to open this" pop-up hidden
Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?" Зарегистрировать приложение, вычислить хэш и ассоциировать его с расширением без всплывающего окна "Каким образом вы хотите открыть этот файл?"
@ -1057,6 +1057,10 @@ StartLayout -ShowMorePins
#endregion Start menu #endregion Start menu
#region UWP apps #region UWP apps
# Uninstall UWP apps using the pop-up dialog box
# Удалить UWP-приложения, используя всплывающее диалоговое окно
UninstallUWPApps
<# <#
Uninstall UWP apps for all users using the pop-up dialog box Uninstall UWP apps for all users using the pop-up dialog box
If the "For All Users" is checked apps packages will not be installed for new users If the "For All Users" is checked apps packages will not be installed for new users

Loading…
Cancel
Save