Browse Source

6.6.2 — 06.03.2024

master
Dmitry Nefedov 10 months ago
parent
commit
c6b281a12a
  1. 8
      README.md
  2. 8
      README_de-de.md
  3. 8
      README_uk-ua.md
  4. 13
      Wrapper/Config/config_Windows_10.json
  5. 17
      Wrapper/Config/config_Windows_10_LTSC.json
  6. 15
      Wrapper/Config/config_Windows_11.json
  7. 20
      Wrapper/Localizations/de-DE/tooltip_Windows_10.json
  8. 18
      Wrapper/Localizations/de-DE/tooltip_Windows_11.json
  9. 16
      Wrapper/Localizations/en-US/tooltip_Windows_10.json
  10. 16
      Wrapper/Localizations/en-US/tooltip_Windows_11.json
  11. 16
      Wrapper/Localizations/ru-RU/tooltip_Windows_10.json
  12. 16
      Wrapper/Localizations/ru-RU/tooltip_Windows_11.json
  13. BIN
      Wrapper/SophiaScriptWrapper.exe
  14. 14
      sophia_script_versions.json
  15. 6
      src/Sophia_Script_for_Windows_10/Functions.ps1
  16. 2
      src/Sophia_Script_for_Windows_10/Localizations/de-DE/Sophia.psd1
  17. 2
      src/Sophia_Script_for_Windows_10/Localizations/en-US/Sophia.psd1
  18. 2
      src/Sophia_Script_for_Windows_10/Localizations/es-ES/Sophia.psd1
  19. 2
      src/Sophia_Script_for_Windows_10/Localizations/fr-FR/Sophia.psd1
  20. 2
      src/Sophia_Script_for_Windows_10/Localizations/hu-HU/Sophia.psd1
  21. 2
      src/Sophia_Script_for_Windows_10/Localizations/it-IT/Sophia.psd1
  22. 2
      src/Sophia_Script_for_Windows_10/Localizations/pl-PL/Sophia.psd1
  23. 2
      src/Sophia_Script_for_Windows_10/Localizations/pt-BR/Sophia.psd1
  24. 2
      src/Sophia_Script_for_Windows_10/Localizations/ru-RU/Sophia.psd1
  25. 2
      src/Sophia_Script_for_Windows_10/Localizations/tr-TR/Sophia.psd1
  26. 2
      src/Sophia_Script_for_Windows_10/Localizations/uk-UA/Sophia.psd1
  27. 2
      src/Sophia_Script_for_Windows_10/Localizations/zh-CN/Sophia.psd1
  28. 307
      src/Sophia_Script_for_Windows_10/Module/Sophia.psm1
  29. 12
      src/Sophia_Script_for_Windows_10/Sophia.ps1
  30. 6
      src/Sophia_Script_for_Windows_10_LTSC_2019/Functions.ps1
  31. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/de-DE/Sophia.psd1
  32. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/en-US/Sophia.psd1
  33. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/es-ES/Sophia.psd1
  34. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/fr-FR/Sophia.psd1
  35. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/hu-HU/Sophia.psd1
  36. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/it-IT/Sophia.psd1
  37. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/pl-PL/Sophia.psd1
  38. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/pt-BR/Sophia.psd1
  39. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/ru-RU/Sophia.psd1
  40. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/tr-TR/Sophia.psd1
  41. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/uk-UA/Sophia.psd1
  42. 2
      src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/zh-CN/Sophia.psd1
  43. 217
      src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1
  44. 12
      src/Sophia_Script_for_Windows_10_LTSC_2019/Sophia.ps1
  45. 6
      src/Sophia_Script_for_Windows_10_LTSC_2021/Functions.ps1
  46. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/de-DE/Sophia.psd1
  47. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/en-US/Sophia.psd1
  48. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/es-ES/Sophia.psd1
  49. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/fr-FR/Sophia.psd1
  50. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/hu-HU/Sophia.psd1
  51. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/it-IT/Sophia.psd1
  52. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/pl-PL/Sophia.psd1
  53. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/pt-BR/Sophia.psd1
  54. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/ru-RU/Sophia.psd1
  55. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/tr-TR/Sophia.psd1
  56. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/uk-UA/Sophia.psd1
  57. 2
      src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/zh-CN/Sophia.psd1
  58. 221
      src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1
  59. 12
      src/Sophia_Script_for_Windows_10_LTSC_2021/Sophia.ps1
  60. 6
      src/Sophia_Script_for_Windows_10_PowerShell_7/Functions.ps1
  61. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/de-DE/Sophia.psd1
  62. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/en-US/Sophia.psd1
  63. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/es-ES/Sophia.psd1
  64. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/fr-FR/Sophia.psd1
  65. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/hu-HU/Sophia.psd1
  66. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/it-IT/Sophia.psd1
  67. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/pl-PL/Sophia.psd1
  68. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/pt-BR/Sophia.psd1
  69. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/ru-RU/Sophia.psd1
  70. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/tr-TR/Sophia.psd1
  71. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/uk-UA/Sophia.psd1
  72. 2
      src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/zh-CN/Sophia.psd1
  73. 307
      src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1
  74. 12
      src/Sophia_Script_for_Windows_10_PowerShell_7/Sophia.ps1
  75. 6
      src/Sophia_Script_for_Windows_11/Functions.ps1
  76. 2
      src/Sophia_Script_for_Windows_11/Localizations/de-DE/Sophia.psd1
  77. 2
      src/Sophia_Script_for_Windows_11/Localizations/en-US/Sophia.psd1
  78. 2
      src/Sophia_Script_for_Windows_11/Localizations/es-ES/Sophia.psd1
  79. 2
      src/Sophia_Script_for_Windows_11/Localizations/fr-FR/Sophia.psd1
  80. 2
      src/Sophia_Script_for_Windows_11/Localizations/hu-HU/Sophia.psd1
  81. 2
      src/Sophia_Script_for_Windows_11/Localizations/it-IT/Sophia.psd1
  82. 2
      src/Sophia_Script_for_Windows_11/Localizations/pl-PL/Sophia.psd1
  83. 2
      src/Sophia_Script_for_Windows_11/Localizations/pt-BR/Sophia.psd1
  84. 2
      src/Sophia_Script_for_Windows_11/Localizations/ru-RU/Sophia.psd1
  85. 2
      src/Sophia_Script_for_Windows_11/Localizations/tr-TR/Sophia.psd1
  86. 2
      src/Sophia_Script_for_Windows_11/Localizations/uk-UA/Sophia.psd1
  87. 2
      src/Sophia_Script_for_Windows_11/Localizations/zh-CN/Sophia.psd1
  88. 306
      src/Sophia_Script_for_Windows_11/Module/Sophia.psm1
  89. 12
      src/Sophia_Script_for_Windows_11/Sophia.ps1
  90. 6
      src/Sophia_Script_for_Windows_11_PowerShell_7/Functions.ps1
  91. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/de-DE/Sophia.psd1
  92. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/en-US/Sophia.psd1
  93. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/es-ES/Sophia.psd1
  94. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/fr-FR/Sophia.psd1
  95. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/hu-HU/Sophia.psd1
  96. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/it-IT/Sophia.psd1
  97. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/pl-PL/Sophia.psd1
  98. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/pt-BR/Sophia.psd1
  99. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/ru-RU/Sophia.psd1
  100. 2
      src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/tr-TR/Sophia.psd1

8
README.md

@ -114,10 +114,10 @@
| Version | Marketing name | Build | Editions |
|:-----------------------------------------|--------------------:|:-----------:|:-------------------:|
| Windows 11 Insider Preview 24H2 | 2024 Update | 22509+ | Home/Pro/Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3085+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.3996+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.3930+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5329+ | Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3155+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.4046+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.4046+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5458+ | Enterprise |
### Warning

8
README_de-de.md

@ -114,10 +114,10 @@
| Version | Marketing name | Build | Editions |
|:-----------------------------------------|--------------------:|:-----------:|:-------------------:|
| Windows 11 Insider Preview 24H2 | 2024 Update | 22509+ | Home/Pro/Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3085+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.3996+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.3930+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5329+ | Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3155+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.4046+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.4046+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5458+ | Enterprise |
### Warnung

8
README_uk-ua.md

@ -114,10 +114,10 @@
| Версія | Маркетингова назва | Збіркa | Видання |
|:-----------------------------------------|--------------------:|:-----------:|:-------------------:|
| Windows 11 Insider Preview 24H2 | 2024 Update | 22509+ | Home/Pro/Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3085+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.3996+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.3930+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5329+ | Enterprise |
| Windows 11 23H2 | 2023 Update | 22631.3155+ | Home/Pro/Enterprise |
| Windows 10 x64 22H2 | 2022 Update | 19045.4046+ | Home/Pro/Enterprise |
| Windows 10 x64 21H2 Enterprise LTSC 2021 | October 2021 Update | 19044.4046+ | Enterprise |
| Windows 10 x64 1809 Enterprise LTSC 2019 | October 2018 Update | 17763.5458+ | Enterprise |
### Увага

13
Wrapper/Config/config_Windows_10.json

@ -1632,21 +1632,12 @@
"Function": "InstallDotNetRuntimes -Runtimes",
"Arg": {
"Zero": {
"Tag": "NET6x86"
},
"One": {
"Tag": "NET6x64"
},
"Two": {
"Tag": "NET7x86"
},
"Three": {
"One": {
"Tag": "NET7x64"
},
"Four": {
"Tag": "NET8x86"
},
"Five": {
"Two": {
"Tag": "NET8x64"
}
},

17
Wrapper/Config/config_Windows_10_LTSC.json

@ -1559,28 +1559,17 @@
"Function": "InstallDotNetRuntimes -Runtimes",
"Arg": {
"Zero": {
"Tag": "NET6x86"
},
"One": {
"Tag": "NET6x64"
},
"Two": {
"Tag": "NET7x86"
},
"Three": {
"One": {
"Tag": "NET7x64"
},
"Four": {
"Tag": "NET8x86"
},
"Five": {
"Two": {
"Tag": "NET8x64"
}
},
"Preset": "",
"WindowsDefault": "",
"LTSC2019": "true",
"LTSC2021": "true"
"WindowsDefault": ""
},
{
"Region": "System",

15
Wrapper/Config/config_Windows_11.json

@ -1558,25 +1558,16 @@
"Function": "InstallDotNetRuntimes -Runtimes",
"Arg": {
"Zero": {
"Tag": "NET6x86"
},
"One": {
"Tag": "NET6x64"
},
"Two": {
"Tag": "NET7x86"
},
"Three": {
"One": {
"Tag": "NET7x64"
},
"Four": {
"Tag": "NET8x86"
},
"Five": {
"Two": {
"Tag": "NET8x64"
}
},
"Preset": "012345",
"Preset": "",
"WindowsDefault": ""
},
{

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

@ -1385,7 +1385,7 @@
"Two": {
"Tag": "Extension",
"ToolTip": "Erweiterung."
},
}
"Three": {
"Tag": "Icon",
"ToolTip": "Pfad zum Symbol."
@ -1435,29 +1435,17 @@
{
"Region": "System",
"Function": "InstallDotNetRuntimes -Runtimes",
"ToolTip": "Installieren Sie die neueste .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"ToolTip": "Installieren Sie die neueste .NET Desktop Runtime 6, 7, 8 x64.",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

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

@ -1373,29 +1373,17 @@
{
"Region": "System",
"Function": "InstallDotNetRuntimes -Runtimes",
"ToolTip": "Installieren Sie die neueste .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"ToolTip": "Installieren Sie die neueste .NET Desktop Runtime 6, 7, 8 x64.",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

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

@ -1438,26 +1438,14 @@
"ToolTip": "Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

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

@ -1376,26 +1376,14 @@
"ToolTip": "Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

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

@ -1438,26 +1438,14 @@
"ToolTip": "Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

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

@ -1376,26 +1376,14 @@
"ToolTip": "Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64).",
"Arg": {
"Zero": {
"Tag": "NET6x86",
"ToolTip": ".NET Desktop Runtime 6 x86."
},
"One": {
"Tag": "NET6x64",
"ToolTip": ".NET Desktop Runtime 6 x64."
},
"Two": {
"Tag": "NET7x86",
"ToolTip": ".NET Desktop Runtime 7 x86."
},
"Three": {
"One": {
"Tag": "NET7x64",
"ToolTip": ".NET Desktop Runtime 7 x64."
},
"Four": {
"Tag": "NET8x86",
"ToolTip": ".NET Desktop Runtime 8 x86."
},
"Five": {
"Two": {
"Tag": "NET8x64",
"ToolTip": ".NET Desktop Runtime 8 x64."
}

BIN
Wrapper/SophiaScriptWrapper.exe

Binary file not shown.

14
sophia_script_versions.json

@ -1,9 +1,9 @@
{
"Sophia_Script_Windows_10_PowerShell_5_1": "5.18.1",
"Sophia_Script_Windows_10_PowerShell_7": "5.18.1",
"Sophia_Script_Windows_10_LTSC2019": "5.8.1",
"Sophia_Script_Windows_10_LTSC2021": "5.18.1",
"Sophia_Script_Windows_11_PowerShell_5_1": "6.6.1",
"Sophia_Script_Windows_11_PowerShell_7": "6.6.1",
"Sophia_Script_Wrapper": "2.6.17"
"Sophia_Script_Windows_10_PowerShell_5_1": "5.18.2",
"Sophia_Script_Windows_10_PowerShell_7": "5.18.2",
"Sophia_Script_Windows_10_LTSC2019": "5.8.2",
"Sophia_Script_Windows_10_LTSC2021": "5.18.2",
"Sophia_Script_Windows_11_PowerShell_5_1": "6.6.2",
"Sophia_Script_Windows_11_PowerShell_7": "6.6.2",
"Sophia_Script_Wrapper": "2.6.18"
}

6
src/Sophia_Script_for_Windows_10/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_10/Localizations/de-DE/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Das Skript unterstützt nur 64-Bit-Windows.
UnsupportedOSBuild = Das Skript unterstützt Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 kompiliert keinen Code, wenn der Benutzername nicht-lateinische Zeichen (einschließlich Emoji) enthält und in Kleinbuchstaben geschrieben ist. Bitte verwenden Sie PowerShell 7.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: 19045.4123+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_10/Localizations/en-US/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = The script supports 64-bit Windows only.
UnsupportedOSBuild = The script supports Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 does not compile code if the username contains non-Latin characters (including emoji) and is written in lowercase. Please, use PowerShell 7.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: 19045.4123+. Run Windows Update and try again.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_10/Localizations/es-ES/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = El script sólo es compatible con Windows de 64 bits.
UnsupportedOSBuild = El script es compatible con versión Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 no compila código si el nombre de usuario contiene caracteres no latinos (incluidos los emoji) y está escrito en minúsculas. Por favor, utiliza PowerShell 7.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: 19045.4123+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/fr-FR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Le script n'est compatible qu'avec Windows 64 bits.
UnsupportedOSBuild = Le script supporte les versions Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 ne compile pas le code si le nom d'utilisateur contient des caractères non latins (y compris emoji) et est écrit en minuscules. Veuillez utiliser PowerShell 7.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: 19045.4123+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/hu-HU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = A szkript csak a 64 bites Windows-t támogatja.
UnsupportedOSBuild = A szkript támogatja a Windows 10 22H2 verzióját.
NonLatinUsernameWarning = A PowerShell 5.1 nem fordít kódot, ha a felhasználónév nem latin betűket tartalmaz (beleértve az emojikat is), és kisbetűvel van írva. Kérjük, használja a PowerShell 7-et.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: 19045.4123+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_10/Localizations/it-IT/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Lo script supporta solo Windows a 64 bit.
UnsupportedOSBuild = Lo script supporta Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 non compila il codice se il nome utente contiene caratteri non latini (compresi gli emoji) ed è scritto in minuscolo. Si prega di utilizzare PowerShell 7.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: 19045.4123+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_10/Localizations/pl-PL/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Skrypt obsługuje tylko 64-bitowe systemy Windows.
UnsupportedOSBuild = Skrypt obsługuje system Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 nie kompiluje kodu, jeśli nazwa użytkownika zawiera znaki spoza alfabetu łacińskiego (w tym emoji) i jest zapisana małymi literami. Prosimy o używanie PowerShell 7.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: 19045.4123+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/pt-BR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = O guião suporta apenas Windows de 64 bits.
UnsupportedOSBuild = O script suporta versões Windows 10 22H2.
NonLatinUsernameWarning = O PowerShell 5.1 não compilará o código se o nome de usuário contiver caracteres não latinos (inclusive emoji) e estiver escrito em letras minúsculas. Por favor, use o PowerShell 7.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: 19045.4123+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/ru-RU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт поддерживает только 64-битную версию Windows.
UnsupportedOSBuild = Скрипт поддерживает Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 не компилирует код, если имя пользователя содержит нелатинские символы (включая эмодзи) и написано со строчной буквы. Пожалуйста, используйте PowerShell 7.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: 19045.4123+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/tr-TR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Komut dosyası yalnızca 64 bit Windows'u destekler.
UnsupportedOSBuild = Komut dosyası Windows 10 22H2'u destekler.
NonLatinUsernameWarning = PowerShell 5.1, kullanıcı adı Latin olmayan karakterler içeriyorsa (emoji dahil) ve küçük harfle yazılmışsa kodu derlemez. Lütfen PowerShell 7 kullanın.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: 19045.4123+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

2
src/Sophia_Script_for_Windows_10/Localizations/uk-UA/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт підтримує тільки 64-розрядну версію Windows.
UnsupportedOSBuild = Скрипт підтримує Windows 10 22H2.
NonLatinUsernameWarning = PowerShell 5.1 не компілює код, якщо ім'я користувача містить нелатинські символи (включно з емодзі) і написане з малої літери. Будь ласка, використовуйте PowerShell 7.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: 19045.4123+. Запустіть Windows Update і повторіть спробу.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: {2}+. Запустіть Windows Update і повторіть спробу.
UnsupportedLanguageMode = Сесія PowerShell працює в обмеженому режимі.
LoggedInUserNotAdmin = Поточний користувач, що увійшов, не має прав адміністратора.
UnsupportedPowerShell = Ви намагаєтеся запустити скрипт в PowerShell {0}.{1}. Запустіть скрипт у відповідній версії PowerShell.

2
src/Sophia_Script_for_Windows_10/Localizations/zh-CN/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = 该脚本仅支持64位Windows
UnsupportedOSBuild = 该脚本支持Windows 10版本22H2和更高版本
NonLatinUsernameWarning = 如果用户名包含非拉丁字符包括表情符号且以小写字母书写PowerShell 5.1 将无法编译代码请使用 PowerShell 7
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: 19045.4123+运行Windows Update并再次尝试
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: {2}+运行Windows Update并再次尝试
UnsupportedLanguageMode = PowerShell会话在有限的语言模式下运行
LoggedInUserNotAdmin = 登录的用户没有管理员的权利
UnsupportedPowerShell = 你想通过PowerShell {0}.{1}运行脚本在适当的PowerShell版本中运行该脚本

307
src/Sophia_Script_for_Windows_10/Module/Sophia.psm1

@ -2,8 +2,8 @@
.SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -172,89 +172,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
}
# Check whether Microsoft Edge as being a system component was removed by harmful tweakers
if (-not (Test-Path -Path "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe"))
{
Write-Information -MessageData "" -InformationAction Continue
# Extract the localized "Please wait..." string from shell32.dll
Write-Verbose -Message ([WinAPI.GetStrings]::GetString(12612)) -Verbose
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
try
{
# Download Microsoft Edge Stable x64
# https://edgeupdates.microsoft.com/api/products?view=enterprise
$Parameters = @{
Uri = "https://edgeupdates.microsoft.com/api/products?view=enterprise"
UseBasicParsing = $true
Verbose = $true
}
$EdgeLinks = Invoke-RestMethod @Parameters
$EdgeURL = (($EdgeLinks | Where-Object -FilterScript {$_.Product -eq "Stable"}).Releases | Where-Object -FilterScript {($_.Platform -eq "Windows") -and ($_.Architecture -eq "x64")} | Select-Object -Index 1).Artifacts.Location
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
$Parameters = @{
Uri = $EdgeURL
OutFile = "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi"
UseBasicParsing = $true
Verbose = $true
}
Invoke-Webrequest @Parameters
# Install Microsoft Edge Stable x64
Start-Process -FilePath "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -ArgumentList "/passive /norestart DONOTCREATEDESKTOPSHORTCUT=TRUE" -Wait
Remove-Item -Path "$env:Public\Desktop\Microsoft Edge.lnk" -Force -ErrorAction Ignore
Start-Sleep -Seconds 5
try
{
& "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe" --no-first-run --noerrdialogs --no-default-browser-check --start-maximized
}
catch
{
Write-Warning -Message ($Localization.WindowsComponentBroken -f "Microsoft Edge")
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
exit
}
Stop-Process -Name msedge -Force -ErrorAction Ignore
Remove-Item -Path "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -Force
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com")
Write-Error -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
}
# Detect Windows bitness
if (-not [System.Environment]::Is64BitOperatingSystem)
{
@ -631,9 +548,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -710,13 +624,53 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
"19045"
{
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 4123)
# Check whether the current module version is the latest one
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
return
}
try
{
# https://github.com/farag2/Sophia-Script-for-Windows/blob/master/supported_windows_builds.json
$Parameters = @{
Uri = "https://raw.githubusercontent.com/farag2/Sophia-Script-for-Windows/master/supported_windows_builds.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestSupportedBuild = (Invoke-RestMethod @Parameters).Windows_10
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://github.com")
Write-Error -Message ($Localization.NoResponse -f "https://github.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
# Check whether Windows minor build version is 4123 minimum
# https://learn.microsoft.com/en-us/windows/release-health/release-information#windows-10-current-versions-by-servicing-option
$LatestSupportedBuild = 0
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
# We may use Test-Path -Path variable:LatestSupportedBuild
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt $LatestSupportedBuild)
{
# Check Windows minor build version
# https://support.microsoft.com/en-us/topic/windows-10-update-history-8127c2c6-6edf-4fdf-8b9f-0f7be1ef3562
$CurrentBuild = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name CurrentBuild
$UBR = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR)
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR, $LatestSupportedBuild)
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -776,9 +730,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -908,7 +859,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
{
Write-Verbose -Message ($Localization.WindowsComponentBroken -f [WinAPI.GetStrings]::GetIndirectString("@%SystemRoot%\system32\schedsvc.dll,-100")) -Verbose
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows/releases/latest"
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -4849,9 +4799,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -4975,9 +4922,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -5488,9 +5432,6 @@ public static bool MarkFileDelete (string sourcefile)
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -6966,9 +6907,6 @@ function WindowsCapabilities
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -7314,9 +7252,6 @@ function IPv6Component
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -10481,9 +10416,6 @@ function InstallVCRedist
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -10542,10 +10474,10 @@ function InstallVCRedist
<#
.SYNOPSIS
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
.EXAMPLE
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
.LINK
https://dotnet.microsoft.com/en-us/download/dotnet
@ -10562,7 +10494,7 @@ function InstallDotNetRuntimes
Mandatory = $true,
ParameterSetName = "Runtimes"
)]
[ValidateSet("NET6x86", "NET6x64", "NET7x86", "NET7x64", "NET8x86", "NET8x64")]
[ValidateSet("NET6x64", "NET7x64", "NET8x64")]
[string[]]
$Runtimes
)
@ -10578,9 +10510,6 @@ function InstallDotNetRuntimes
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
}
@ -10596,50 +10525,6 @@ function InstallDotNetRuntimes
{
switch ($Runtime)
{
NET6x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/6
# .NET Desktop Runtime 6 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.6 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# Install .NET Desktop Runtime 6
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/6.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 6 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET6x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10684,50 +10569,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/7
# .NET Desktop Runtime 7 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.7 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 7
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/7.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 7 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10771,52 +10612,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/8
# .NET Desktop Runtime 8 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.8 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 8
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/8.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 8 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x64
{
@ -10860,7 +10655,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
}
}
@ -11168,9 +10962,6 @@ function Install-WSL
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}

12
src/Sophia_Script_for_Windows_10/Sophia.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
Default preset file for "Sophia Script for Windows 10"
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -70,7 +70,7 @@ param
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -1007,12 +1007,12 @@ UninstallPCHealthCheck
InstallVCRedist
<#
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 x64
https://dotnet.microsoft.com/en-us/download/dotnet
#>
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
# Enable proxying only blocked sites from the unified registry of Roskomnadzor. The function is applicable for Russia only
# Включить проксирование только заблокированных сайтов из единого реестра Роскомнадзора. Функция применима только для России

6
src/Sophia_Script_for_Windows_10_LTSC_2019/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v5.8.1
Date: 03.03.2024
Version: v5.8.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows 10 | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows 10 | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/de-DE/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Das Skript unterstützt nur 64-Bit-Windows.
UnsupportedOSBuild = Das Skript unterstützt Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 kompiliert keinen Code, wenn der Benutzername nicht-lateinische Zeichen (einschließlich Emoji) enthält und in Kleinbuchstaben geschrieben ist. Bitte verwenden Sie PowerShell 7.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: 17763.5458+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/en-US/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = The script supports 64-bit Windows only.
UnsupportedOSBuild = The script supports Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 does not compile code if the username contains non-Latin characters (including emoji) and is written in lowercase. Please, use PowerShell 7.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: 17763.5458+. Run Windows Update and try again.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/es-ES/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = El script sólo es compatible con Windows de 64 bits.
UnsupportedOSBuild = El script es compatible con versión Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 no compila código si el nombre de usuario contiene caracteres no latinos (incluidos los emoji) y está escrito en minúsculas. Por favor, utiliza PowerShell 7.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: 17763.5458+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/fr-FR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Le script n'est compatible qu'avec Windows 64 bits.
UnsupportedOSBuild = Le script supporte le version Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 ne compile pas le code si le nom d'utilisateur contient des caractères non latins (y compris emoji) et est écrit en minuscules. Veuillez utiliser PowerShell 7.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: 17763.5458+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/hu-HU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = A szkript csak a 64 bites Windows-t támogatja.
UnsupportedOSBuild = A szkript támogatja a Windows 10 Enterprise LTSC 2019 kiadást.
NonLatinUsernameWarning = A PowerShell 5.1 nem fordít kódot, ha a felhasználónév nem latin betűket tartalmaz (beleértve az emojikat is), és kisbetűvel van írva. Kérjük, használja a PowerShell 7-et.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: 17763.5458+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/it-IT/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Lo script supporta solo Windows a 64 bit.
UnsupportedOSBuild = Lo script supporta Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 non compila il codice se il nome utente contiene caratteri non latini (compresi gli emoji) ed è scritto in minuscolo. Si prega di utilizzare PowerShell 7.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: 17763.5458+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/pl-PL/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Skrypt obsługuje tylko 64-bitowe systemy Windows.
UnsupportedOSBuild = Skrypt obsługuje system Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 nie kompiluje kodu, jeśli nazwa użytkownika zawiera znaki spoza alfabetu łacińskiego (w tym emoji) i jest zapisana małymi literami. Prosimy o używanie PowerShell 7.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: 17763.5458+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/pt-BR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = O guião suporta apenas Windows de 64 bits.
UnsupportedOSBuild = O script suporta versões Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = O PowerShell 5.1 não compilará o código se o nome de usuário contiver caracteres não latinos (inclusive emoji) e estiver escrito em letras minúsculas. Por favor, use o PowerShell 7.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: 17763.5458+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/ru-RU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт поддерживает только 64-битную версию Windows.
UnsupportedOSBuild = Скрипт поддерживает только Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 не компилирует код, если имя пользователя содержит нелатинские символы (включая эмодзи) и написано со строчной буквы. Пожалуйста, используйте PowerShell 7.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: 17763.5458+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/tr-TR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Komut dosyası yalnızca 64 bit Windows'u destekler.
UnsupportedOSBuild = Komut dosyası Windows 10 Enterprise LTSC 2019'u destekler.
NonLatinUsernameWarning = PowerShell 5.1, kullanıcı adı Latin olmayan karakterler içeriyorsa (emoji dahil) ve küçük harfle yazılmışsa kodu derlemez. Lütfen PowerShell 7 kullanın.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: 17763.5458+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/uk-UA/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт підтримує тільки 64-розрядну версію Windows.
UnsupportedOSBuild = Скрипт підтримує тільки Windows 10 Enterprise LTSC 2019.
NonLatinUsernameWarning = PowerShell 5.1 не компілює код, якщо ім'я користувача містить нелатинські символи (включно з емодзі) і написане з малої літери. Будь ласка, використовуйте PowerShell 7.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: 17763.5458+. Запустіть Windows Update і повторіть спробу.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: {2}+. Запустіть Windows Update і повторіть спробу.
UnsupportedLanguageMode = Сесія PowerShell працює в обмеженому режимі.
LoggedInUserNotAdmin = Поточний користувач, що увійшов, не має прав адміністратора.
UnsupportedPowerShell = Ви намагаєтеся запустити скрипт в PowerShell {0}.{1}. Запустіть скрипт у відповідній версії PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2019/Localizations/zh-CN/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = 该脚本仅支持64位Windows
UnsupportedOSBuild = 该脚本支持Windows 10版本Enterprise LTSC 2019
NonLatinUsernameWarning = 如果用户名包含非拉丁字符包括表情符号且以小写字母书写PowerShell 5.1 将无法编译代码请使用 PowerShell 7
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: 17763.5458+运行Windows Update并再次尝试
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: {2}+运行Windows Update并再次尝试
UnsupportedLanguageMode = PowerShell会话在有限的语言模式下运行
LoggedInUserNotAdmin = 登录的用户没有管理员的权利
UnsupportedPowerShell = 你想通过PowerShell {0}.{1}运行脚本在适当的PowerShell版本中运行该脚本

217
src/Sophia_Script_for_Windows_10_LTSC_2019/Module/Sophia.psm1

@ -2,8 +2,8 @@
.SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.8.1
Date: 03.03.2024
Version: v5.8.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -514,9 +514,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -601,13 +598,53 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
"17763"
{
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 5458)
# Check whether the current module version is the latest one
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
return
}
try
{
# Check whether Windows minor build version is 5458 minimum
# https://learn.microsoft.com/en-us/windows/release-health/release-information#windows-10-current-versions-by-servicing-option
# https://github.com/farag2/Sophia-Script-for-Windows/blob/master/supported_windows_builds.json
$Parameters = @{
Uri = "https://raw.githubusercontent.com/farag2/Sophia-Script-for-Windows/master/supported_windows_builds.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestSupportedBuild = (Invoke-RestMethod @Parameters).Windows_10_LTSC_2019
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://github.com")
Write-Error -Message ($Localization.NoResponse -f "https://github.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
$LatestSupportedBuild = 0
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
# We may use Test-Path -Path variable:LatestSupportedBuild
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt $LatestSupportedBuild)
{
# Check Windows minor build version
# https://support.microsoft.com/en-us/topic/windows-10-and-windows-server-2019-update-history-725fc2e1-4443-6831-a5ca-51ff5cbcb059
$CurrentBuild = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name CurrentBuild
$UBR = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR)
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR, $LatestSupportedBuild)
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -664,9 +701,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -796,7 +830,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
{
Write-Verbose -Message ($Localization.WindowsComponentBroken -f [WinAPI.GetStrings]::GetIndirectString("@%SystemRoot%\system32\schedsvc.dll,-100")) -Verbose
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows/releases/latest"
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -3790,9 +3823,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -3916,9 +3946,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -5589,9 +5616,6 @@ function WindowsCapabilities
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -5937,9 +5961,6 @@ function IPv6Component
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -8708,9 +8729,6 @@ function InstallVCRedist
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -8769,10 +8787,10 @@ function InstallVCRedist
<#
.SYNOPSIS
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
.EXAMPLE
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
.LINK
https://dotnet.microsoft.com/en-us/download/dotnet
@ -8789,7 +8807,7 @@ function InstallDotNetRuntimes
Mandatory = $true,
ParameterSetName = "Runtimes"
)]
[ValidateSet("NET6x86", "NET6x64", "NET7x86", "NET7x64", "NET8x86", "NET8x64")]
[ValidateSet("NET6x64", "NET7x64", "NET8x64")]
[string[]]
$Runtimes
)
@ -8805,9 +8823,6 @@ function InstallDotNetRuntimes
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
}
@ -8823,50 +8838,6 @@ function InstallDotNetRuntimes
{
switch ($Runtime)
{
NET6x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/6
# .NET Desktop Runtime 6 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.6 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# Install .NET Desktop Runtime 6
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/6.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 6 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET6x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -8911,50 +8882,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/7
# .NET Desktop Runtime 7 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.7 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 7
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/7.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 7 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -8999,51 +8926,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/8
# .NET Desktop Runtime 8 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.8 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 8
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/8.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 8 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x64
{
@ -9087,7 +8969,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
}
}

12
src/Sophia_Script_for_Windows_10_LTSC_2019/Sophia.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
Default preset file for "Sophia Script for Windows 10 LTSC 2019"
Version: v5.8.1
Date: 03.03.2024
Version: v5.8.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -70,7 +70,7 @@ param
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2019 v5.8.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -788,12 +788,12 @@ ActiveHours -Automatically
InstallVCRedist
<#
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 x64
https://dotnet.microsoft.com/en-us/download/dotnet
#>
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
# Enable proxying only blocked sites from the unified registry of Roskomnadzor. The function is applicable for Russia only
# Включить проксирование только заблокированных сайтов из единого реестра Роскомнадзора. Функция применима только для России

6
src/Sophia_Script_for_Windows_10_LTSC_2021/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/de-DE/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Das Skript unterstützt nur 64-Bit-Windows.
UnsupportedOSBuild = Das Skript unterstützt Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 kompiliert keinen Code, wenn der Benutzername nicht-lateinische Zeichen (einschließlich Emoji) enthält und in Kleinbuchstaben geschrieben ist. Bitte verwenden Sie PowerShell 7.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: 19044.4046+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/en-US/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = The script supports 64-bit Windows only.
UnsupportedOSBuild = The script supports Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 does not compile code if the username contains non-Latin characters (including emoji) and is written in lowercase. Please, use PowerShell 7.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: 19044.4046+. Run Windows Update and try again.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/es-ES/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = El script sólo es compatible con Windows de 64 bits.
UnsupportedOSBuild = El script es compatible con versión Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 no compila código si el nombre de usuario contiene caracteres no latinos (incluidos los emoji) y está escrito en minúsculas. Por favor, utiliza PowerShell 7.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: 19044.4046+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/fr-FR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Le script n'est compatible qu'avec Windows 64 bits.
UnsupportedOSBuild = Le script supporte les versions Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 ne compile pas le code si le nom d'utilisateur contient des caractères non latins (y compris emoji) et est écrit en minuscules. Veuillez utiliser PowerShell 7.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: 19044.4046+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/hu-HU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = A szkript csak a 64 bites Windows-t támogatja.
UnsupportedOSBuild = A szkript támogatja a Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = A PowerShell 5.1 nem fordít kódot, ha a felhasználónév nem latin betűket tartalmaz (beleértve az emojikat is), és kisbetűvel van írva. Kérjük, használja a PowerShell 7-et.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: 19044.4046+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/it-IT/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Lo script supporta solo Windows a 64 bit.
UnsupportedOSBuild = Lo script supporta Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 non compila il codice se il nome utente contiene caratteri non latini (compresi gli emoji) ed è scritto in minuscolo. Si prega di utilizzare PowerShell 7.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: 19044.4046+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/pl-PL/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Skrypt obsługuje tylko 64-bitowe systemy Windows.
UnsupportedOSBuild = Skrypt obsługuje system Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 nie kompiluje kodu, jeśli nazwa użytkownika zawiera znaki spoza alfabetu łacińskiego (w tym emoji) i jest zapisana małymi literami. Prosimy o używanie PowerShell 7.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: 19044.4046+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/pt-BR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = O guião suporta apenas Windows de 64 bits.
UnsupportedOSBuild = O script suporta versões Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = O PowerShell 5.1 não compilará o código se o nome de usuário contiver caracteres não latinos (inclusive emoji) e estiver escrito em letras minúsculas. Por favor, use o PowerShell 7.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: 19044.4046+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/ru-RU/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт поддерживает только 64-битную версию Windows.
UnsupportedOSBuild = Скрипт поддерживает только Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 не компилирует код, если имя пользователя содержит нелатинские символы (включая эмодзи) и написано со строчной буквы. Пожалуйста, используйте PowerShell 7.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: 19044.4046+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/tr-TR/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Komut dosyası yalnızca 64 bit Windows'u destekler.
UnsupportedOSBuild = Komut dosyası Windows 10 Enterprise LTSC 2021'u destekler.
NonLatinUsernameWarning = PowerShell 5.1, kullanıcı adı Latin olmayan karakterler içeriyorsa (emoji dahil) ve küçük harfle yazılmışsa kodu derlemez. Lütfen PowerShell 7 kullanın.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: 19044.4046+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/uk-UA/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = Скрипт підтримує тільки 64-розрядну версію Windows.
UnsupportedOSBuild = Скрипт підтримує тільки Windows 10 Enterprise LTSC 2021.
NonLatinUsernameWarning = PowerShell 5.1 не компілює код, якщо ім'я користувача містить нелатинські символи (включно з емодзі) і написане з малої літери. Будь ласка, використовуйте PowerShell 7.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: 19044.4046+. Запустіть Windows Update і повторіть спробу.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: {2}+. Запустіть Windows Update і повторіть спробу.
UnsupportedLanguageMode = Сесія PowerShell працює в обмеженому режимі.
LoggedInUserNotAdmin = Поточний користувач, що увійшов, не має прав адміністратора.
UnsupportedPowerShell = Ви намагаєтеся запустити скрипт в PowerShell {0}.{1}. Запустіть скрипт у відповідній версії PowerShell.

2
src/Sophia_Script_for_Windows_10_LTSC_2021/Localizations/zh-CN/Sophia.psd1

@ -2,7 +2,7 @@
UnsupportedOSBitness = 该脚本仅支持64位Windows
UnsupportedOSBuild = 该脚本支持Windows 10 Enterprise LTSC 2021
NonLatinUsernameWarning = 如果用户名包含非拉丁字符包括表情符号且以小写字母书写PowerShell 5.1 将无法编译代码请使用 PowerShell 7
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: 19044.4046+运行Windows Update并再次尝试
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: {2}+运行Windows Update并再次尝试
UnsupportedLanguageMode = PowerShell会话在有限的语言模式下运行
LoggedInUserNotAdmin = 登录的用户没有管理员的权利
UnsupportedPowerShell = 你想通过PowerShell {0}.{1}运行脚本在适当的PowerShell版本中运行该脚本

221
src/Sophia_Script_for_Windows_10_LTSC_2021/Module/Sophia.psm1

@ -2,8 +2,8 @@
.SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -514,9 +514,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -601,13 +598,53 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
"19044"
{
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 4046)
# Check whether the current module version is the latest one
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
return
}
try
{
# https://github.com/farag2/Sophia-Script-for-Windows/blob/master/supported_windows_builds.json
$Parameters = @{
Uri = "https://raw.githubusercontent.com/farag2/Sophia-Script-for-Windows/master/supported_windows_builds.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestSupportedBuild = (Invoke-RestMethod @Parameters).Windows_10_LTSC_2021
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://github.com")
Write-Error -Message ($Localization.NoResponse -f "https://github.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
$LatestSupportedBuild = 0
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
# We may use Test-Path -Path variable:LatestSupportedBuild
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt $LatestSupportedBuild)
{
# Check whether Windows minor build version is 4046 minimum
# https://learn.microsoft.com/en-us/windows/release-health/release-information#windows-10-current-versions-by-servicing-option
# Check Windows minor build version
# https://support.microsoft.com/en-us/topic/windows-10-update-history-8127c2c6-6edf-4fdf-8b9f-0f7be1ef3562
$CurrentBuild = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name CurrentBuild
$UBR = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR)
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR, $LatestSupportedBuild)
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -664,9 +701,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -796,7 +830,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
{
Write-Verbose -Message ($Localization.WindowsComponentBroken -f [WinAPI.GetStrings]::GetIndirectString("@%SystemRoot%\system32\schedsvc.dll,-100")) -Verbose
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows/releases/latest"
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -4162,9 +4195,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -4288,9 +4318,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -5977,9 +6004,6 @@ function WindowsCapabilities
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -6325,9 +6349,6 @@ function IPv6Component
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -9335,9 +9356,6 @@ function InstallVCRedist
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -9396,10 +9414,10 @@ function InstallVCRedist
<#
.SYNOPSIS
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
.EXAMPLE
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
.LINK
https://dotnet.microsoft.com/en-us/download/dotnet
@ -9416,7 +9434,7 @@ function InstallDotNetRuntimes
Mandatory = $true,
ParameterSetName = "Runtimes"
)]
[ValidateSet("NET6x86", "NET6x64", "NET7x86", "NET7x64", "NET8x86", "NET8x64")]
[ValidateSet("NET6x64", "NET7x64", "NET8x64")]
[string[]]
$Runtimes
)
@ -9432,9 +9450,6 @@ function InstallDotNetRuntimes
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
}
@ -9450,50 +9465,6 @@ function InstallDotNetRuntimes
{
switch ($Runtime)
{
NET6x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/6
# .NET Desktop Runtime 6 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.6 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# Install .NET Desktop Runtime 6
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/6.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 6 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET6x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -9538,50 +9509,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/7
# .NET Desktop Runtime 7 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.7 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 7
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/7.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 7 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -9625,52 +9552,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/8
# .NET Desktop Runtime 8 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.8 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 8
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/8.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 8 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x64
{
@ -9714,7 +9595,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
}
}
@ -10022,9 +9902,6 @@ function Install-WSL
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}

12
src/Sophia_Script_for_Windows_10_LTSC_2021/Sophia.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
Default preset file for "Sophia Script for Windows 10 LTSC 2021"
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -70,7 +70,7 @@ param
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 LTSC 2021 v5.18.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -886,12 +886,12 @@ ActiveHours -Automatically
InstallVCRedist
<#
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 x64
https://dotnet.microsoft.com/en-us/download/dotnet
#>
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
# Enable proxying only blocked sites from the unified registry of Roskomnadzor. The function is applicable for Russia only
# Включить проксирование только заблокированных сайтов из единого реестра Роскомнадзора. Функция применима только для России

6
src/Sophia_Script_for_Windows_10_PowerShell_7/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.1 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.2 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/de-DE/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Das Skript unterstützt nur 64-Bit-Windows.
UnsupportedOSBuild = Das Skript unterstützt Windows 10 22H2.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: 19045.4123+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 10-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/en-US/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = The script supports 64-bit Windows only.
UnsupportedOSBuild = The script supports Windows 10 22H2.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: 19045.4123+. Run Windows Update and try again.
UpdateWarning = Your Windows 10 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/es-ES/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = El script sólo es compatible con Windows de 64 bits.
UnsupportedOSBuild = El script es compatible con versión Windows 10 22H2.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: 19045.4123+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 10: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/fr-FR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Le script n'est compatible qu'avec Windows 64 bits.
UnsupportedOSBuild = Le script supporte les versions Windows 10 22H2.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: 19045.4123+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 10: {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/hu-HU/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = A szkript csak a 64 bites Windows-t támogatja.
UnsupportedOSBuild = A szkript támogatja a Windows 10 22H2 verzióját.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: 19045.4123+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 10 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/it-IT/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Lo script supporta solo Windows a 64 bit.
UnsupportedOSBuild = Lo script supporta Windows 10 22H2.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: 19045.4123+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 10 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/pl-PL/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Skrypt obsługuje tylko 64-bitowe systemy Windows.
UnsupportedOSBuild = Skrypt obsługuje system Windows 10 22H2.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: 19045.4123+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 10: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/pt-BR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = O guião suporta apenas Windows de 64 bits.
UnsupportedOSBuild = O script suporta versões Windows 10 22H2.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: 19045.4123+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 10: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/ru-RU/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Скрипт поддерживает только 64-битную версию Windows.
UnsupportedOSBuild = Скрипт поддерживает Windows 10 22H2.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: 19045.4123+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 10: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/tr-TR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Komut dosyası yalnızca 64 bit Windows'u destekler.
UnsupportedOSBuild = Komut dosyası Windows 10 22H2'u destekler.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: 19045.4123+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 10 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/uk-UA/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = Скрипт підтримує тільки 64-розрядну версію Windows.
UnsupportedOSBuild = Скрипт підтримує Windows 10 22H2.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: 19045.4123+. Запустіть Windows Update і повторіть спробу.
UpdateWarning = Ваш білд Windows 10: {0}.{1}. Підтримувані збірки: {2}+. Запустіть Windows Update і повторіть спробу.
UnsupportedLanguageMode = Сесія PowerShell працює в обмеженому режимі.
LoggedInUserNotAdmin = Поточний користувач, що увійшов, не має прав адміністратора.
UnsupportedPowerShell = Ви намагаєтеся запустити скрипт в PowerShell {0}.{1}. Запустіть скрипт у відповідній версії PowerShell.

2
src/Sophia_Script_for_Windows_10_PowerShell_7/Localizations/zh-CN/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBitness = 该脚本仅支持64位Windows
UnsupportedOSBuild = 该脚本支持Windows 10版本22H2和更高版本
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: 19045.4123+运行Windows Update并再次尝试
UpdateWarning = 您的Windows 10构建: {0}.{1}支持的构建: {2}+运行Windows Update并再次尝试
UnsupportedLanguageMode = PowerShell会话在有限的语言模式下运行
LoggedInUserNotAdmin = 登录的用户没有管理员的权利
UnsupportedPowerShell = 你想通过PowerShell {0}.{1}运行脚本在适当的PowerShell版本中运行该脚本

307
src/Sophia_Script_for_Windows_10_PowerShell_7/Module/Sophia.psm1

@ -2,8 +2,8 @@
.SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -151,89 +151,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
}
# Check whether Microsoft Edge as being a system component was removed by harmful tweakers
if (-not (Test-Path -Path "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe"))
{
Write-Information -MessageData "" -InformationAction Continue
# Extract the localized "Please wait..." string from shell32.dll
Write-Verbose -Message ([WinAPI.GetStrings]::GetString(12612)) -Verbose
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
try
{
# Download Microsoft Edge Stable x64
# https://edgeupdates.microsoft.com/api/products?view=enterprise
$Parameters = @{
Uri = "https://edgeupdates.microsoft.com/api/products?view=enterprise"
UseBasicParsing = $true
Verbose = $true
}
$EdgeLinks = Invoke-RestMethod @Parameters
$EdgeURL = (($EdgeLinks | Where-Object -FilterScript {$_.Product -eq "Stable"}).Releases | Where-Object -FilterScript {($_.Platform -eq "Windows") -and ($_.Architecture -eq "x64")} | Select-Object -Index 1).Artifacts.Location
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
$Parameters = @{
Uri = $EdgeURL
OutFile = "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi"
UseBasicParsing = $true
Verbose = $true
}
Invoke-Webrequest @Parameters
# Install Microsoft Edge Stable x64
Start-Process -FilePath "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -ArgumentList "/passive /norestart DONOTCREATEDESKTOPSHORTCUT=TRUE" -Wait
Remove-Item -Path "$env:Public\Desktop\Microsoft Edge.lnk" -Force -ErrorAction Ignore
Start-Sleep -Seconds 5
try
{
& "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe" --no-first-run --noerrdialogs --no-default-browser-check --start-maximized
}
catch
{
Write-Warning -Message ($Localization.WindowsComponentBroken -f "Microsoft Edge")
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
exit
}
Stop-Process -Name msedge -Force -ErrorAction Ignore
Remove-Item -Path "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -Force
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com")
Write-Error -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
}
# Detect Windows bitness
if (-not [System.Environment]::Is64BitOperatingSystem)
{
@ -612,9 +529,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -696,13 +610,53 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
"19045"
{
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 4123)
# Check whether the current module version is the latest one
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
return
}
try
{
# https://github.com/farag2/Sophia-Script-for-Windows/blob/master/supported_windows_builds.json
$Parameters = @{
Uri = "https://raw.githubusercontent.com/farag2/Sophia-Script-for-Windows/master/supported_windows_builds.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestSupportedBuild = (Invoke-RestMethod @Parameters).Windows_10
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://github.com")
Write-Error -Message ($Localization.NoResponse -f "https://github.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
# Check whether Windows minor build version is 4123 minimum
# https://learn.microsoft.com/en-us/windows/release-health/release-information#windows-10-current-versions-by-servicing-option
$LatestSupportedBuild = 0
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
# We may use Test-Path -Path variable:LatestSupportedBuild
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt $LatestSupportedBuild)
{
# Check Windows minor build version
# https://support.microsoft.com/en-us/topic/windows-10-update-history-8127c2c6-6edf-4fdf-8b9f-0f7be1ef3562
$CurrentBuild = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name CurrentBuild
$UBR = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR)
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR, $LatestSupportedBuild)
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -762,9 +716,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -894,7 +845,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
{
Write-Verbose -Message ($Localization.WindowsComponentBroken -f [WinAPI.GetStrings]::GetIndirectString("@%SystemRoot%\system32\schedsvc.dll,-100")) -Verbose
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows/releases/latest"
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -4838,9 +4788,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -4964,9 +4911,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -5477,9 +5421,6 @@ public static bool MarkFileDelete (string sourcefile)
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -6955,9 +6896,6 @@ function WindowsCapabilities
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -7303,9 +7241,6 @@ function IPv6Component
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -10470,9 +10405,6 @@ function InstallVCRedist
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -10531,10 +10463,10 @@ function InstallVCRedist
<#
.SYNOPSIS
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
.EXAMPLE
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
.LINK
https://dotnet.microsoft.com/en-us/download/dotnet
@ -10551,7 +10483,7 @@ function InstallDotNetRuntimes
Mandatory = $true,
ParameterSetName = "Runtimes"
)]
[ValidateSet("NET6x86", "NET6x64", "NET7x86", "NET7x64", "NET8x86", "NET8x64")]
[ValidateSet("NET6x64", "NET7x64", "NET8x64")]
[string[]]
$Runtimes
)
@ -10567,9 +10499,6 @@ function InstallDotNetRuntimes
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
}
@ -10585,50 +10514,6 @@ function InstallDotNetRuntimes
{
switch ($Runtime)
{
NET6x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/6
# .NET Desktop Runtime 6 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.6 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# Install .NET Desktop Runtime 6
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/6.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 6 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET6x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10673,50 +10558,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/7
# .NET Desktop Runtime 7 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.7 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 7
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/7.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 7 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10760,52 +10601,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/8
# .NET Desktop Runtime 8 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.8 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 8
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/8.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 8 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x64
{
@ -10849,7 +10644,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
}
}
@ -11157,9 +10951,6 @@ function Install-WSL
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}

12
src/Sophia_Script_for_Windows_10_PowerShell_7/Sophia.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
Default preset file for "Sophia Script for Windows 10 (PowerShell 7)"
Version: v5.18.1
Date: 03.03.2024
Version: v5.18.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -70,7 +70,7 @@ param
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.1 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 10 v5.18.2 (PowerShell 7) | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
# PowerShell 7 doesn't load en-us localization automatically if there is no localization folder in user's language which is determined by $PSUICulture
# https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/import-localizeddata?view=powershell-7.3
@ -1016,12 +1016,12 @@ UninstallPCHealthCheck
InstallVCRedist
<#
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 x64
https://dotnet.microsoft.com/en-us/download/dotnet
#>
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
# Enable proxying only blocked sites from the unified registry of Roskomnadzor. The function is applicable for Russia only
# Включить проксирование только заблокированных сайтов из единого реестра Роскомнадзора. Функция применима только для России

6
src/Sophia_Script_for_Windows_11/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v6.6.1
Date: 03.03.2024
Version: v6.6.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_11/Localizations/de-DE/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Das Skript unterstützt Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 kompiliert keinen Code, wenn der Benutzername nicht-lateinische Zeichen (einschließlich Emoji) enthält und in Kleinbuchstaben geschrieben ist. Bitte verwenden Sie PowerShell 7.
UpdateWarning = Ihr Windows 11-Build: {0}.{1}. Unterstützter Builds: 22631.3235+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 11-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_11/Localizations/en-US/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = The script supports Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 does not compile code if the username contains non-Latin characters (including emoji) and is written in lowercase. Please, use PowerShell 7.
UpdateWarning = Your Windows 11 build: {0}.{1}. Supported builds: 22631.3235+. Run Windows Update and try again.
UpdateWarning = Your Windows 11 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_11/Localizations/es-ES/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = El script es compatible con Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 no compila código si el nombre de usuario contiene caracteres no latinos (incluidos los emoji) y está escrito en minúsculas. Por favor, utiliza PowerShell 7.
UpdateWarning = Su build de Windows 11: {0}.{1}. Compilaciones compatibles: 22631.3235+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 11: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/fr-FR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Le script prend en charge Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 ne compile pas le code si le nom d'utilisateur contient des caractères non latins (y compris emoji) et est écrit en minuscules. Veuillez utiliser PowerShell 7.
UpdateWarning = Votre version de Windows 11 : {0}.{1}. Versions prises en charge: 22631.3235+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 11 : {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/hu-HU/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = A szkript támogatja a Windows 11 23H2+ rendszert.
NonLatinUsernameWarning = A PowerShell 5.1 nem fordít kódot, ha a felhasználónév nem latin betűket tartalmaz (beleértve az emojikat is), és kisbetűvel van írva. Kérjük, használja a PowerShell 7-et.
UpdateWarning = Az Ön Windows 11 építése: {0}.{1}. Támogatott buildek: 22631.3235+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 11 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_11/Localizations/it-IT/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Lo script supporta Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 non compila il codice se il nome utente contiene caratteri non latini (compresi gli emoji) ed è scritto in minuscolo. Si prega di utilizzare PowerShell 7.
UpdateWarning = La tua build di Windows 11 {0}.{1} non è supportata. Build supportate: 22631.3235+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 11 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_11/Localizations/pl-PL/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Skrypt obsługuje system Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 nie kompiluje kodu, jeśli nazwa użytkownika zawiera znaki spoza alfabetu łacińskiego (w tym emoji) i jest zapisana małymi literami. Prosimy o używanie PowerShell 7.
UpdateWarning = Twoja wersja systemu Windows 11: {0}.{1}. Obsługiwane kompilacje: 22631.3235+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 11: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/pt-BR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = O script suporta Windows 11 23H2+.
NonLatinUsernameWarning = O PowerShell 5.1 não compilará o código se o nome de usuário contiver caracteres não latinos (inclusive emoji) e estiver escrito em letras minúsculas. Por favor, use o PowerShell 7.
UpdateWarning = La tua build di Windows 11: {0}.{1}. Build suportadas: 22631.3235+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 11: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/ru-RU/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Скрипт поддерживает Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 не компилирует код, если имя пользователя содержит нелатинские символы (включая эмодзи) и написано со строчной буквы. Пожалуйста, используйте PowerShell 7.
UpdateWarning = Ваш билд Windows 11: {0}.{1}. Поддерживаемые сборки: 22631.3235+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 11: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/tr-TR/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Komut dosyası Windows 11 23H2+' destekler.
NonLatinUsernameWarning = PowerShell 5.1, kullanıcı adı Latin olmayan karakterler içeriyorsa (emoji dahil) ve küçük harfle yazılmışsa kodu derlemez. Lütfen PowerShell 7 kullanın.
UpdateWarning = Windows 11 yapınız: {0}.{1}. Desteklenen yapılar: 22631.3235+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 11 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

2
src/Sophia_Script_for_Windows_11/Localizations/uk-UA/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Скрипт підтримує Windows 11 23H2+.
NonLatinUsernameWarning = PowerShell 5.1 не компілює код, якщо ім'я користувача містить нелатинські символи (включно з емодзі) і написане з малої літери. Будь ласка, використовуйте PowerShell 7.
UpdateWarning = Ваш білд Windows 11: {0}.{1}. Підтримувані збірки: 22631.3235+. Запустіть Windows Update і повторіть спробу.
UpdateWarning = Ваш білд Windows 11: {0}.{1}. Підтримувані збірки: {2}+. Запустіть Windows Update і повторіть спробу.
UnsupportedLanguageMode = Сесія PowerShell працює в обмеженому режимі.
LoggedInUserNotAdmin = Поточний користувач, що увійшов, не має прав адміністратора.
UnsupportedPowerShell = Ви намагаєтеся запустити скрипт в PowerShell {0}.{1}. Запустіть скрипт у відповідній версії PowerShell.

2
src/Sophia_Script_for_Windows_11/Localizations/zh-CN/Sophia.psd1

@ -1,7 +1,7 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = 脚本支持Windows 11 23H2+
NonLatinUsernameWarning = 如果用户名包含非拉丁字符包括表情符号且以小写字母书写PowerShell 5.1 将无法编译代码请使用 PowerShell 7
UpdateWarning = 您的Windows 11构建: {0}.{1}支持的构建: 22631.3235+运行Windows Update并再次尝试
UpdateWarning = 您的Windows 11构建: {0}.{1}支持的构建: {2}+运行Windows Update并再次尝试
UnsupportedLanguageMode = PowerShell会话在有限的语言模式下运行
LoggedInUserNotAdmin = 登录的用户没有管理员的权利
UnsupportedPowerShell = 你想通过PowerShell {0}.{1}运行脚本在适当的PowerShell版本中运行该脚本

306
src/Sophia_Script_for_Windows_11/Module/Sophia.psm1

@ -2,8 +2,8 @@
.SYNOPSIS
Sophia Script is a PowerShell module for Windows 10 & Windows 11 fine-tuning and automating the routine tasks
Version: v6.6.1
Date: 03.03.2024
Version: v6.6.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -171,89 +171,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
}
# Check whether Microsoft Edge as being a system component was removed by harmful tweakers
if (-not (Test-Path -Path "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe"))
{
Write-Information -MessageData "" -InformationAction Continue
# Extract the localized "Please wait..." string from shell32.dll
Write-Verbose -Message ([WinAPI.GetStrings]::GetString(12612)) -Verbose
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
try
{
# Download Microsoft Edge Stable x64
# https://edgeupdates.microsoft.com/api/products?view=enterprise
$Parameters = @{
Uri = "https://edgeupdates.microsoft.com/api/products?view=enterprise"
UseBasicParsing = $true
Verbose = $true
}
$EdgeLinks = Invoke-RestMethod @Parameters
$EdgeURL = (($EdgeLinks | Where-Object -FilterScript {$_.Product -eq "Stable"}).Releases | Where-Object -FilterScript {($_.Platform -eq "Windows") -and ($_.Architecture -eq "x64")} | Select-Object -Index 1).Artifacts.Location
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
$Parameters = @{
Uri = $EdgeURL
OutFile = "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi"
UseBasicParsing = $true
Verbose = $true
}
Invoke-Webrequest @Parameters
# Install Microsoft Edge Stable x64
Start-Process -FilePath "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -ArgumentList "/passive /norestart DONOTCREATEDESKTOPSHORTCUT=TRUE" -Wait
Remove-Item -Path "$env:Public\Desktop\Microsoft Edge.lnk" -Force -ErrorAction Ignore
Start-Sleep -Seconds 5
try
{
& "${env:ProgramFiles(x86)}\Microsoft\Edge\Application\msedge.exe" --no-first-run --noerrdialogs --no-default-browser-check --start-maximized
}
catch
{
Write-Warning -Message ($Localization.WindowsComponentBroken -f "Microsoft Edge")
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
exit
}
Stop-Process -Name msedge -Force -ErrorAction Ignore
Remove-Item -Path "$DownloadsFolder\MicrosoftEdgeEnterpriseX64.msi" -Force
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com")
Write-Error -Message ($Localization.NoResponse -f "https://edgeupdates.microsoft.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
}
# Check the language mode
if ($ExecutionContext.SessionState.LanguageMode -ne "FullLanguage")
{
@ -607,9 +524,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -686,13 +600,38 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
"22631"
{
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt 3235)
# Check whether the current module version is the latest one
try
{
# Check the internet connection
$Parameters = @{
Name = "dns.msftncsi.com"
Server = "1.1.1.1"
DnsOnly = $true
ErrorAction = "Stop"
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
return
}
try
{
# Check whether Windows minor build version is 3235 minimum
# https://learn.microsoft.com/en-us/windows/release-health/windows11-release-information#windows-11-current-versions
# https://github.com/farag2/Sophia-Script-for-Windows/blob/master/supported_windows_builds.json
$Parameters = @{
Uri = "https://raw.githubusercontent.com/farag2/Sophia-Script-for-Windows/master/supported_windows_builds.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestSupportedBuild = (Invoke-RestMethod @Parameters).Windows_11
if ((Get-ItemPropertyValue -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR) -lt $LatestSupportedBuild)
{
# Check Windows minor build version
# https://support.microsoft.com/en-us/topic/windows-11-version-23h2-update-history-59875222-b990-4bd9-932f-91a5954de434
$CurrentBuild = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name CurrentBuild
$UBR = Get-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows nt\CurrentVersion" -Name UBR
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR)
Write-Warning -Message ($Localization.UpdateWarning -f $CurrentBuild.CurrentBuild, $UBR.UBR, $LatestSupportedBuild)
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -713,6 +652,18 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
exit
}
}
catch [System.Net.WebException]
{
Write-Warning -Message ($Localization.NoResponse -f "https://github.com")
Write-Error -Message ($Localization.NoResponse -f "https://github.com") -ErrorAction SilentlyContinue
}
}
catch [System.ComponentModel.Win32Exception]
{
Write-Warning -Message $Localization.NoInternetConnection
Write-Error -Message $Localization.NoInternetConnection -ErrorAction SilentlyContinue
}
}
}
# Enable back the SysMain service if it was disabled by harmful tweakers
@ -752,9 +703,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -884,7 +832,6 @@ public static extern bool SetForegroundWindow(IntPtr hWnd);
{
Write-Verbose -Message ($Localization.WindowsComponentBroken -f [WinAPI.GetStrings]::GetIndirectString("@%SystemRoot%\system32\schedsvc.dll,-100")) -Verbose
Start-Process -FilePath "https://github.com/farag2/Sophia-Script-for-Windows/releases/latest"
Start-Process -FilePath "https://t.me/sophia_chat"
Start-Process -FilePath "https://discord.gg/sSryhaEv79"
@ -4244,9 +4191,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -4370,9 +4314,6 @@ function Cursors
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -4883,9 +4824,6 @@ public static bool MarkFileDelete (string sourcefile)
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -6358,9 +6296,6 @@ function WindowsCapabilities
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -6910,9 +6845,6 @@ function IPv6Component
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -9902,9 +9834,6 @@ function InstallVCRedist
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -9963,10 +9892,10 @@ function InstallVCRedist
<#
.SYNOPSIS
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
.EXAMPLE
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
.LINK
https://dotnet.microsoft.com/en-us/download/dotnet
@ -9983,7 +9912,7 @@ function InstallDotNetRuntimes
Mandatory = $true,
ParameterSetName = "Runtimes"
)]
[ValidateSet("NET6x86", "NET6x64", "NET7x86", "NET7x64", "NET8x86", "NET8x64")]
[ValidateSet("NET6x64", "NET7x64", "NET8x64")]
[string[]]
$Runtimes
)
@ -9999,9 +9928,6 @@ function InstallDotNetRuntimes
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
}
@ -10017,50 +9943,6 @@ function InstallDotNetRuntimes
{
switch ($Runtime)
{
NET6x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/6
# .NET Desktop Runtime 6 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.6 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# Install .NET Desktop Runtime 6
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/6.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 6 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET6x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10105,50 +9987,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/7
# .NET Desktop Runtime 7 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.7 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 7
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/7.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 7 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET7x64
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
@ -10193,51 +10031,6 @@ function InstallDotNetRuntimes
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x86
{
if ([System.Version](Get-AppxPackage -Name Microsoft.DesktopAppInstaller -ErrorAction Ignore).Version -ge [System.Version]"1.17")
{
# https://github.com/microsoft/winget-pkgs/tree/master/manifests/m/Microsoft/DotNet/DesktopRuntime/8
# .NET Desktop Runtime 8 x86
winget install --id=Microsoft.DotNet.DesktopRuntime.8 --architecture x86 --exact --force --accept-source-agreements
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
Get-ChildItem -Path "$env:TEMP\WinGet" -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
else
{
# .NET Desktop Runtime 8
# https://github.com/dotnet/core/blob/main/release-notes/releases-index.json
$Parameters = @{
Uri = "https://dotnetcli.blob.core.windows.net/dotnet/release-metadata/8.0/releases.json"
Verbose = $true
UseBasicParsing = $true
}
$LatestRelease = (Invoke-RestMethod @Parameters)."latest-release"
$DownloadsFolder = Get-ItemPropertyValue -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\User Shell Folders" -Name "{374DE290-123F-4565-9164-39C4925E467B}"
# .NET Desktop Runtime 8 x86
$Parameters = @{
Uri = "https://dotnetcli.azureedge.net/dotnet/Runtime/$LatestRelease/dotnet-runtime-$LatestRelease-win-x86.exe"
OutFile = "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe"
UseBasicParsing = $true
Verbose = $true
}
Invoke-WebRequest @Parameters
Start-Process -FilePath "$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe" -ArgumentList "/install /passive /norestart" -Wait
# PowerShell 5.1 (7.5 too) interprets 8.3 file name literally, if an environment variable contains a non-Latin word
# https://github.com/PowerShell/PowerShell/issues/21070
$Paths = @(
"$DownloadsFolder\dotnet-runtime-$LatestRelease-win-x86.exe",
"$env:TEMP\Microsoft_.NET_Runtime*.log"
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
NET8x64
{
@ -10281,7 +10074,6 @@ function InstallDotNetRuntimes
)
Get-ChildItem -Path $Paths -Force -ErrorAction Ignore | Remove-Item -Recurse -Force -ErrorAction Ignore
}
}
}
}
@ -10402,9 +10194,6 @@ function Install-WSA
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}
@ -10673,9 +10462,6 @@ function Install-WSL
}
if ((Resolve-DnsName @Parameters).IPAddress -notcontains "131.107.255.255")
{
Write-Information -MessageData "" -InformationAction Continue
Write-Verbose -Message $Localization.Skipped -Verbose
return
}

12
src/Sophia_Script_for_Windows_11/Sophia.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
Default preset file for "Sophia Script for Windows 11"
Version: v6.6.1
Date: 03.03.2024
Version: v6.6.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -69,7 +69,7 @@ param
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-LocalizedData -BindingVariable Global:Localization -BaseDirectory $PSScriptRoot\Localizations -FileName Sophia
@ -979,12 +979,12 @@ DefaultTerminalApp -WindowsTerminal
InstallVCRedist
<#
Install the latest .NET Desktop Runtime 6, 7, 8 (x86/x64)
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 (x86/x64)
Install the latest .NET Desktop Runtime 6, 7, 8 x64
Установить последнюю версию .NET Desktop Runtime 6, 7, 8 x64
https://dotnet.microsoft.com/en-us/download/dotnet
#>
InstallDotNetRuntimes -Runtimes NET6x86, NET6x64, NET7x86, NET7x64, NET8x86, NET8x64
InstallDotNetRuntimes -Runtimes NET6x64, NET7x64, NET8x64
# Enable proxying only blocked sites from the unified registry of Roskomnadzor. The function is applicable for Russia only
# Включить проксирование только заблокированных сайтов из единого реестра Роскомнадзора. Функция применима только для России

6
src/Sophia_Script_for_Windows_11_PowerShell_7/Functions.ps1

@ -2,8 +2,8 @@
.SYNOPSIS
The TAB completion for functions and their arguments
Version: v6.6.1
Date: 03.03.2024
Version: v6.6.2
Date: 06.03.2024
Copyright (c) 20142024 farag
Copyright (c) 20192024 farag & Inestic
@ -50,7 +50,7 @@ function Sophia
Clear-Host
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.1 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
$Host.UI.RawUI.WindowTitle = "Sophia Script for Windows 11 v6.6.2 | Made with $([System.Char]::ConvertFromUtf32(0x1F497)) of Windows | $([System.Char]0x00A9) farag & Inestic, 2014$([System.Char]0x2013)2024"
Remove-Module -Name Sophia -Force -ErrorAction Ignore
Import-Module -Name $PSScriptRoot\Manifest\Sophia.psd1 -PassThru -Force

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/de-DE/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Das Skript unterstützt Windows 11 23H2+.
UpdateWarning = Ihr Windows 11-Build: {0}.{1}. Unterstützter Builds: 22631.3235+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UpdateWarning = Ihr Windows 11-Build: {0}.{1}. Unterstützter Builds: {2}+. Führen Sie Windows Update aus und versuchen Sie es erneut.
UnsupportedLanguageMode = Die PowerShell-Sitzung wird in einem eingeschränkten Sprachmodus ausgeführt.
LoggedInUserNotAdmin = Der angemeldete Benutzer hat keine Administratorrechte.
UnsupportedPowerShell = Sie versuchen ein Skript über PowerShell {0}.{1} auszuführen. Das Skript in der entsprechenden PowerShell-Version ausführen.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/en-US/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = The script supports Windows 11 23H2+.
UpdateWarning = Your Windows 11 build: {0}.{1}. Supported builds: 22631.3235+. Run Windows Update and try again.
UpdateWarning = Your Windows 11 build: {0}.{1}. Supported builds: {2}+. Run Windows Update and try again.
UnsupportedLanguageMode = The PowerShell session in running in a limited language mode.
LoggedInUserNotAdmin = The logged-on user doesn't have admin rights.
UnsupportedPowerShell = You're trying to run script via PowerShell {0}.{1}. Run the script in the appropriate PowerShell version.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/es-ES/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = El script es compatible con Windows 11 23H2+.
UpdateWarning = Su build de Windows 11: {0}.{1}. Compilaciones compatibles: 22631.3235+. Ejecute Windows Update y vuelva a intentarlo.
UpdateWarning = Su build de Windows 11: {0}.{1}. Compilaciones compatibles: {2}+. Ejecute Windows Update y vuelva a intentarlo.
UnsupportedLanguageMode = Sesión de PowerShell ejecutada en modo de lenguaje limitado.
LoggedInUserNotAdmin = El usuario que inició sesión no tiene derechos de administrador.
UnsupportedPowerShell = Estás intentando ejecutar el script a través de PowerShell {0}.{1}. Ejecute el script en la versión apropiada de PowerShell.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/fr-FR/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Le script prend en charge Windows 11 23H2+.
UpdateWarning = Votre version de Windows 11 : {0}.{1}. Versions prises en charge: 22631.3235+. Exécutez Windows Update et réessayez.
UpdateWarning = Votre version de Windows 11 : {0}.{1}. Versions prises en charge: {2}+. Exécutez Windows Update et réessayez.
UnsupportedLanguageMode = La session PowerShell s'exécute dans un mode de langue limité.
LoggedInUserNotAdmin = L'utilisateur connecté n'a pas de droits d'administrateur.
UnsupportedPowerShell = Vous essayez d'exécuter le script via PowerShell {0}.{1}. Exécutez le script dans la version appropriée de PowerShell.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/hu-HU/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = A szkript támogatja a Windows 11 23H2+ rendszert.
UpdateWarning = Az Ön Windows 11 építése: {0}.{1}. Támogatott buildek: 22631.3235+. Futtassa a Windows Update programot, és próbálja meg újra.
UpdateWarning = Az Ön Windows 11 építése: {0}.{1}. Támogatott buildek: {2}+. Futtassa a Windows Update programot, és próbálja meg újra.
UnsupportedLanguageMode = A PowerShell munkamenet korlátozott nyelvi üzemmódban fut.
LoggedInUserNotAdmin = A bejelentkezett felhasználó nem rendelkezik admin jogokkal.
UnsupportedPowerShell = A PowerShell {0}.{1} segítségével próbálja futtatni a szkriptet. Futtassa a szkriptet a megfelelő PowerShell-verzióban.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/it-IT/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Lo script supporta Windows 11 23H2+.
UpdateWarning = La tua build di Windows 11 {0}.{1} non è supportata. Build supportate: 22631.3235+. Eseguire Windows Update e riprovare.
UpdateWarning = La tua build di Windows 11 {0}.{1} non è supportata. Build supportate: {2}+. Eseguire Windows Update e riprovare.
UnsupportedLanguageMode = La sessione PowerShell è in esecuzione in modalità lingua limitata.
LoggedInUserNotAdmin = L'utente in suo non ha i diritti di amministratore.
UnsupportedPowerShell = Stai cercando di eseguire lo script tramite PowerShell {0}.{1}. Esegui lo script nella versione di PowerShell appropriata.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/pl-PL/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Skrypt obsługuje system Windows 11 23H2+.
UpdateWarning = Twoja wersja systemu Windows 11: {0}.{1}. Obsługiwane kompilacje: 22631.3235+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UpdateWarning = Twoja wersja systemu Windows 11: {0}.{1}. Obsługiwane kompilacje: {2}+. Uruchom aktualizację systemu Windows i spróbuj ponownie.
UnsupportedLanguageMode = Sesja PowerShell działa w trybie ograniczonego języka.
LoggedInUserNotAdmin = Zalogowany użytkownik nie posiada uprawnień administratora.
UnsupportedPowerShell = Próbujesz uruchomić skrypt przy użyciu PowerShell {0}.{1}. Uruchom skrypt używając odpowiedniej wersji PowerShell.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/pt-BR/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = O script suporta Windows 11 23H2+.
UpdateWarning = La tua build di Windows 11: {0}.{1}. Build suportadas: 22631.3235+. Execute o Windows Update e tente novamente.
UpdateWarning = La tua build di Windows 11: {0}.{1}. Build suportadas: {2}+. Execute o Windows Update e tente novamente.
UnsupportedLanguageMode = A sessão PowerShell em funcionamento em um modo de linguagem limitada.
LoggedInUserNotAdmin = O usuário logado não tem direitos de administrador.
UnsupportedPowerShell = Você está tentando executar o script via PowerShell {0}.{1}. Execute o script na versão apropriada do PowerShell.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/ru-RU/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Скрипт поддерживает Windows 11 23H2+.
UpdateWarning = Ваш билд Windows 11: {0}.{1}. Поддерживаемые сборки: 22631.3235+. Запустите обновление Windows и попробуйте заново.
UpdateWarning = Ваш билд Windows 11: {0}.{1}. Поддерживаемые сборки: {2}+. Запустите обновление Windows и попробуйте заново.
UnsupportedLanguageMode = Сессия PowerShell работает в ограниченном режиме.
LoggedInUserNotAdmin = Текущий вошедший пользователь не обладает правами администратора.
UnsupportedPowerShell = Вы пытаетесь запустить скрипт в PowerShell {0}.{1}. Запустите скрипт в соответствующей версии PowerShell.

2
src/Sophia_Script_for_Windows_11_PowerShell_7/Localizations/tr-TR/Sophia.psd1

@ -1,6 +1,6 @@
ConvertFrom-StringData -StringData @'
UnsupportedOSBuild = Komut dosyası Windows 11 23H2+' destekler.
UpdateWarning = Windows 11 yapınız: {0}.{1}. Desteklenen yapılar: 22631.3235+. Windows Update'i çalıştırın ve tekrar deneyin.
UpdateWarning = Windows 11 yapınız: {0}.{1}. Desteklenen yapılar: {2}+. Windows Update'i çalıştırın ve tekrar deneyin.
UnsupportedLanguageMode = Sınırlı bir dil modunda çalışan PowerShell oturumu.
LoggedInUserNotAdmin = Oturum açan kullanıcının yönetici hakları yok.
UnsupportedPowerShell = Komut dosyasını PowerShell {0}.{1} aracılığıyla çalıştırmaya çalışıyorsunuz. Komut dosyasını uygun PowerShell sürümünde çalıştırın.

Some files were not shown because too many files changed in this diff

Loading…
Cancel
Save