Skip to content
This repository was archived by the owner on Jan 10, 2024. It is now read-only.

Commit 6224261

Browse files
committed
1.0.0-beta.5
1 parent 26afafd commit 6224261

File tree

5 files changed

+175
-16
lines changed

5 files changed

+175
-16
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ This software is in beta. **All scripts are provided as-is and you use them at y
88

99
## Contributing
1010

11-
Contributions are welcome, just make a pull request and we'll accept it if it's actually helpful.
11+
Contributions are welcomed, just make a pull request and we'll accept it if it's actually helpful.
1212

1313
## Execution
14-
Before launching the script(s), run these commands:
14+
Before launching the script, run these commands:
1515

1616
Enable execution of PowerShell scripts:
1717

@@ -21,6 +21,8 @@ Unblock PowerShell scripts and modules within this directory:
2121

2222
PS> ls -Recurse *.ps*1 | Unblock-File
2323

24+
To run WindowsToolbox, run "WindowsToolbox.cmd"
25+
2426
## Liability
2527

2628
**All scripts are provided as-is and you use them at your own risk.**

library/GeneralFunctions.psm1

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# General functions
22

3-
$version = "1.0.0-beta.3"
3+
$version = "1.0.0-beta.5"
44
$build = (Get-CimInstance Win32_OperatingSystem).version
55
$winver = (Get-WmiObject -class Win32_OperatingSystem).Caption
66

@@ -13,7 +13,7 @@ function setup {
1313
$winver = '10'
1414
}
1515
}
16-
function Exit {
16+
function Quit {
1717
stop-process -id $PID
1818
}
1919

@@ -24,6 +24,9 @@ function Restart {
2424
function Info {
2525
Write-Output "Windows Toolbox $version"
2626
Write-Output "Windows build $build"
27+
if ($version -lt "$version") {
28+
Write-Output "Older version of WindowsToolbox is detected, please update WindowsToolbox"
29+
}
2730
Write-Output ""
2831
Write-Output ""
2932
Write-Output "Please read before using WindowsToolbox"

library/PrivacyFunctions.psm1

Lines changed: 55 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
function Disable-Telemetry {
1+
function DisableTelemetry {
22
Write-Output "Disabling telemetry via Group Policies"
33
New-FolderForced -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection"
44
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection" "AllowTelemetry" 0
@@ -22,7 +22,7 @@ function Disable-Telemetry {
2222
"a1621.g.akamai.net"
2323
"a1856.g2.akamai.net"
2424
"a1961.g.akamai.net"
25-
#"a248.e.akamai.net" # makes iTunes download button disappear (#43)
25+
#"a248.e.akamai.net" # makes iTunes download button disappear
2626
"a978.i6g1.akamai.net"
2727
"a.ads1.msn.com"
2828
"a.ads2.msads.net"
@@ -210,12 +210,55 @@ function Disable-Telemetry {
210210
Remove-NetFirewallRule -DisplayName "Block Telemetry IPs" -ErrorAction SilentlyContinue
211211
New-NetFirewallRule -DisplayName "Block Telemetry IPs" -Direction Outbound `
212212
-Action Block -RemoteAddress ([string[]]$ips)
213+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name "AllowTelemetry" -Type DWord -Value 0
214+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Policies\DataCollection" -Name "AllowTelemetry" -Type DWord -Value 0
215+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\DataCollection" -Name "AllowTelemetry" -Type DWord -Value 0
216+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\PreviewBuilds")) {
217+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\PreviewBuilds" -Force | Out-Null
218+
}
219+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\PreviewBuilds" -Name "AllowBuildPreview" -Type DWord -Value 0
220+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\Software Protection Platform")) {
221+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\Software Protection Platform" -Force | Out-Null
222+
}
223+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows NT\CurrentVersion\Software Protection Platform" -Name "NoGenTicket" -Type DWord -Value 1
224+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\SQMClient\Windows")) {
225+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\SQMClient\Windows" -Force | Out-Null
226+
}
227+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\SQMClient\Windows" -Name "CEIPEnable" -Type DWord -Value 0
228+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat")) {
229+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat" -Force | Out-Null
230+
}
231+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat" -Name "AITEnable" -Type DWord -Value 0
232+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\AppCompat" -Name "DisableInventory" -Type DWord -Value 1
233+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\AppV\CEIP")) {
234+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\AppV\CEIP" -Force | Out-Null
235+
}
236+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\AppV\CEIP" -Name "CEIPEnable" -Type DWord -Value 0
237+
If (!(Test-Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\TabletPC")) {
238+
New-Item -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\TabletPC" -Force | Out-Null
239+
}
240+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\TabletPC" -Name "PreventHandwritingDataSharing" -Type DWord -Value 1
241+
If (!(Test-Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\TextInput")) {
242+
New-Item -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\TextInput" -Force | Out-Null
243+
}
244+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\TextInput" -Name "AllowLinguisticDataCollection" -Type DWord -Value 0
245+
Disable-ScheduledTask -TaskName "Microsoft\Windows\Application Experience\Microsoft Compatibility Appraiser" | Out-Null
246+
Disable-ScheduledTask -TaskName "Microsoft\Windows\Application Experience\ProgramDataUpdater" | Out-Null
247+
Disable-ScheduledTask -TaskName "Microsoft\Windows\Autochk\Proxy" | Out-Null
248+
Disable-ScheduledTask -TaskName "Microsoft\Windows\Customer Experience Improvement Program\Consolidator" | Out-Null
249+
Disable-ScheduledTask -TaskName "Microsoft\Windows\Customer Experience Improvement Program\UsbCeip" | Out-Null
250+
Disable-ScheduledTask -TaskName "Microsoft\Windows\DiskDiagnostic\Microsoft-Windows-DiskDiagnosticDataCollector" | Out-Null
251+
# Office 2016 / 2019
252+
Disable-ScheduledTask -TaskName "Microsoft\Office\Office ClickToRun Service Monitor" -ErrorAction SilentlyContinue | Out-Null
253+
Disable-ScheduledTask -TaskName "Microsoft\Office\OfficeTelemetryAgentFallBack2016" -ErrorAction SilentlyContinue | Out-Null
254+
Disable-ScheduledTask -TaskName "Microsoft\Office\OfficeTelemetryAgentLogOn2016" -ErrorAction SilentlyContinue | Out-Null
255+
Write-Output "Done"
213256
}
214257

215258
function PrivacyFixSettings {
216259
# Description:
217-
# This script will try to fix many of the privacy settings for the user. This
218-
# is work in progress!
260+
<# This script will try to fix many of the privacy settings for the user. This
261+
is work in progress!#>
219262

220263
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\New-FolderForced.psm1
221264
Import-Module -DisableNameChecking $PSScriptRoot\..\lib\take-own.psm1
@@ -380,4 +423,12 @@ function DisableAdvertisingID {
380423
}
381424
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\AdvertisingInfo" -Name "DisabledByGroupPolicy" -Type DWord -Value 1
382425
Write-Output "done"
426+
}
427+
428+
function DisableActivityHistory {
429+
Write-Output "Disabling Activity History..."
430+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\System" -Name "EnableActivityFeed" -Type DWord -Value 0
431+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\System" -Name "PublishUserActivities" -Type DWord -Value 0
432+
Set-ItemProperty -Path "HKLM:\SOFTWARE\Policies\Microsoft\Windows\System" -Name "UploadUserActivities" -Type DWord -Value 0
433+
Write-Output "Done"
383434
}

library/Tweaks.psm1

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,7 @@ function TBSingleClick {
8989
Set-ItemProperty -Path "HKCU:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" -Name "LastActiveClick" -Type Dword -Value 0x00000001 -Force
9090
Write-Output "Done"
9191
}
92+
9293
# UI Tweaks
9394

9495
function RemoveThisPClutter {
@@ -130,4 +131,62 @@ function DisableAeroShake {
130131
Write-Output "Disabling Aero Shake..."
131132
Set-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" -Name "DisallowShaking" -Type DWord -Value 1
132133
Write-Output "Done"
134+
}
135+
136+
function DisableActionCenter {
137+
Write-Output "Disabling Action Center (Notification Center)..."
138+
If (!(Test-Path "HKCU:\Software\Policies\Microsoft\Windows\Explorer")) {
139+
New-Item -Path "HKCU:\Software\Policies\Microsoft\Windows\Explorer" | Out-Null
140+
}
141+
Set-ItemProperty -Path "HKCU:\Software\Policies\Microsoft\Windows\Explorer" -Name "DisableNotificationCenter" -Type DWord -Value 1
142+
Set-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\PushNotifications" -Name "ToastEnabled" -Type DWord -Value 0
143+
Write-Output "Done"
144+
}
145+
146+
function DisableAccessibilityKeys {
147+
Write-Output "Disabling accessibility keys prompts..."
148+
Set-ItemProperty -Path "HKCU:\Control Panel\Accessibility\StickyKeys" -Name "Flags" -Type String -Value "506"
149+
Set-ItemProperty -Path "HKCU:\Control Panel\Accessibility\ToggleKeys" -Name "Flags" -Type String -Value "58"
150+
Set-ItemProperty -Path "HKCU:\Control Panel\Accessibility\Keyboard Response" -Name "Flags" -Type String -Value "122"
151+
Write-Output "Done"
152+
}
153+
154+
function FixNoInternetPrompt {
155+
if((Test-Path -LiteralPath "HKLM:\SYSTEM\CurrentControlSet\Services\NlaSvc\Parameters\Internet") -ne $true) { New-Item "HKLM:\SYSTEM\CurrentControlSet\Services\NlaSvc\Parameters\Internet" -force -ea SilentlyContinue };
156+
New-ItemProperty -LiteralPath 'HKLM:\SYSTEM\CurrentControlSet\Services\NlaSvc\Parameters\Internet' -Name 'EnableActiveProbingl' -Value 1 -PropertyType DWord -Force -ea SilentlyContinue;
157+
}
158+
159+
function SetWinXMenuCMD {
160+
Write-Output "Setting Command prompt instead of PowerShell in WinX menu..."
161+
If ([System.Environment]::OSVersion.Version.Build -le 14393) {
162+
Remove-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" -Name "DontUsePowerShellOnWinX" -ErrorAction SilentlyContinue
163+
} Else {
164+
Set-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" -Name "DontUsePowerShellOnWinX" -Type DWord -Value 1
165+
}
166+
}
167+
168+
function ShowBuildNumberOnDesktop {
169+
Write-Output "Showing Windows build number on desktop..."
170+
Set-ItemProperty -Path "HKCU:\Control Panel\Desktop" -Name "PaintDesktopVersion" -Type DWord -Value 1
171+
Write-Output "Done"
172+
}
173+
174+
function ShowExplorerFullPath {
175+
Write-Output "Showing full directory path in Explorer title bar..."
176+
If (!(Test-Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\CabinetState")) {
177+
New-Item -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\CabinetState" -Force | Out-Null
178+
}
179+
Set-ItemProperty -Path "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\CabinetState" -Name "FullPath" -Type DWord -Value 1
180+
Write-Output "Done"
181+
}
182+
183+
function EnableVerboseStartup {
184+
Write-Output "Enabling verbose startup/shutdown status messages..."
185+
if ((Get-CimInstance -Class "Win32_OperatingSystem").ProductType -eq 1) {
186+
Set-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -Name "VerboseStatus" -Type DWord -Value 1
187+
}
188+
else {
189+
Remove-ItemProperty -Path "HKLM:\Software\Microsoft\Windows\CurrentVersion\Policies\System" -Name "VerboseStatus" -ErrorAction SilentlyContinue
190+
}
191+
Write-Output "Done"
133192
}

main.ps1

Lines changed: 52 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ $objects = @{
6666
'Disable App Suggestions',
6767
'Disable Tailored Experiences',
6868
'Disable Advertising ID'
69+
'Disable Activity History'
6970
)"
7071

7172
'Tweaks' = @{
@@ -81,12 +82,24 @@ $objects = @{
8182
'Improve SSD Lifespan (HIGHLY RECOMMENDED IF YOU HAVE AN SSD)'
8283
)"
8384

84-
'UI Tweaks' = "@(
85-
'Remove user folders under This PC',
86-
'Enable dark mode',
87-
'Disable Aero Shake',
88-
'Switch Windows With a Single Click on the Taskbar'
89-
)"
85+
'UI Tweaks' = @{
86+
'Shell tweaks' = "@(
87+
'Enable dark mode',
88+
'Disable Aero Shake',
89+
'Switch Windows With a Single Click on the Taskbar',
90+
'Disable Action Center',
91+
'Disable Accessibility Keys',
92+
'Set Win+X menu to Command Prompt',
93+
'Fix No Internet prompt',
94+
'Enable verbose startup / shutdown messages'
95+
)"
96+
97+
'Explorer tweaks' = "@(
98+
'Remove user folders under This PC',
99+
'Show build number on desktop',
100+
'Show full directory path in Explorer title bar'
101+
)"
102+
}
90103
}
91104

92105
'Install Apps' = @{
@@ -167,6 +180,9 @@ do {
167180
}
168181

169182
# Privacy menu
183+
"Disable Telemetry" {
184+
DisableTelemetry
185+
}
170186

171187
"Privacy Fixes (WIP)" {
172188
PrivacyFixSettings
@@ -183,6 +199,10 @@ do {
183199
"Disable Advertising ID" {
184200
DisableAdvertisingID
185201
}
202+
203+
"Disable Activity History" {
204+
DisableActivityHistory
205+
}
186206

187207
# Install Menu
188208

@@ -347,19 +367,43 @@ do {
347367
}
348368

349369
#UI Tweaks
370+
371+
#Explorer tweaks
350372
"Remove user folders under This PC" {
351373
RemoveThisPClutter
352374
}
375+
"Show build number on desktop" {
376+
ShowBuildNumberOnDesktop
377+
}
378+
"Show full directory path in Explorer's title bar" {
379+
ShowExplorerFullPath
380+
}
381+
382+
#Shell tweaks
353383
"Enable dark mode" {
354384
DarkMode
355385
}
356386
"Disable Aero Share" {
357387
DisableAeroShake
358388
}
359-
360389
"Switch Windows With a Single Click on the Taskbar" {
361390
TBSingleClick
362391
}
392+
"Disable Action Center" {
393+
DisableActionCenter
394+
}
395+
"Disable Accessibility Keys" {
396+
DisableAccessibilityKeys
397+
}
398+
"Fix No Internet prompt" {
399+
FixNoInternetPrompt
400+
}
401+
"Set Win+X menu to Command Prompt" {
402+
SetWinXMenuCMD
403+
}
404+
"Enable verbose startup / shutdown messages" {
405+
EnableVerboseStartup
406+
}
363407

364408
# Undo
365409
"(Re)Enable Telemetry" {
@@ -371,7 +415,7 @@ do {
371415
Info
372416
}
373417
"Exit" {
374-
Exit
418+
Quit
375419
}
376420
"Reboot" {
377421
Restart

0 commit comments

Comments
 (0)