@@ -4,33 +4,12 @@ description: Applies some Revision configurations
44privilege : TrustedInstaller
55actions :
66
7- # Disable transparency and animations for low end devices
8- - !powerShell:
9- runas : currentUserElevated
10- command : |
11- $mem = (Get-CimInstance Win32_PhysicalMemory | Measure-Object Capacity -Sum).Sum
12- if ($mem -lt 9000000000) {
13- [microsoft.win32.registry]::SetValue('HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize', 'EnableTransparency', 0, [Microsoft.Win32.RegistryValueKind]::DWord)
14- [microsoft.win32.registry]::SetValue('HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics', 'MinAnimate', 0, [Microsoft.Win32.RegistryValueKind]::DWord)
15- }
16-
177 # Disable Memory Compression
188 - !powerShell:
199 command : ' Disable-MMAgent -mc'
2010
2111 - !registryValue: {path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Services\Pending\7971f918-a847-4430-9279-4a52d1efe18d', value: 'RegisterWithAU', type: REG_DWORD, data: '0'}
22-
23- # [!] Breaks 'defrag c: -b'
24- # Disable Superfetch for SSDs
25- # Detection of mediaType might not work on VMs
26- # - !powerShell:
27- # command: |
28- # $mediaType = (Get-PhysicalDisk -SerialNumber (Get-Disk -Number (Get-Partition -DriveLetter $env:SystemDrive.Substring(0, 1)).DiskNumber).SerialNumber.TrimStart()).MediaType
29- # if ($mediaType -eq 'SSD') {
30- # $path = ${env:ProgramFiles(x86)} + '\Revision Tool\data\flutter_assets\additionals\DisableSF.bat'
31- # Start-Process -FilePath $path -Wait -NoNewWindow
32- # }
33-
12+
3413 - !cmd:
3514 command : ' setx DOTNET_CLI_TELEMETRY_OPTOUT 1'
3615 runas : currentUserElevated
@@ -88,7 +67,45 @@ actions:
8867 exeDir : true
8968 runas : currentUserElevated
9069 option : " configure-wallpaper"
91- weight : 45
70+ weight : 45
71+
72+ - !powerShell:
73+ command : ' Copy-Item -Path .\WALLPAPER.ps1 -Destination "$env:systemroot\Web\Wallpaper\MeetRevision" -Force'
74+ exeDir : true
75+ option : " configure-wallpaper"
76+
77+ - !powerShell:
78+ command : ' Copy-Item -Path .\WallpaperStartup.cmd -Destination "$env:systemroot\Web\Wallpaper\MeetRevision" -Force'
79+ exeDir : true
80+ option : " configure-wallpaper"
81+
82+ - !powerShell:
83+ command : ' .\Set-Theme.ps1 -WallpaperPath "$env:SystemRoot\Web\Wallpaper\MeetRevision\v2\desktop.jpg" -ThemeExportPath "$env:SystemRoot\Resources\Themes\revi.theme" -SystemMode "Dark" -AppMode "Dark"'
84+ exeDir : true
85+ runas : currentUserElevated
86+ option : " configure-wallpaper, configure-darkmode"
87+
88+ - !powerShell:
89+ command : ' .\Set-Theme.ps1 -WallpaperPath "$env:SystemRoot\Web\Wallpaper\MeetRevision\v2\desktop.jpg" -ThemeExportPath "$env:SystemRoot\Resources\Themes\revi.theme" -SystemMode "Light" -AppMode "Light"'
90+ exeDir : true
91+ runas : currentUserElevated
92+ option : " configure-wallpaper, !configure-darkmode"
93+
94+
95+ # Still necessary to set for W10
96+ # # if dark mode is deselected, then revert to light mode
97+ - !registryValue: {path: 'HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize', value: 'AppsUseLightTheme', type: REG_DWORD, data: '0', option: "configure-darkmode", weight: 70}
98+ - !registryValue: {path: 'HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize', value: 'SystemUsesLightTheme', type: REG_DWORD, data: '0', option: "configure-darkmode", weight: 50}
99+ - !registryValue: {path: 'HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize', value: 'AppsUseLightTheme', type: REG_DWORD, data: '1', option: "!configure-darkmode", weight: 70}
100+ - !registryValue: {path: 'HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize', value: 'SystemUsesLightTheme', type: REG_DWORD, data: '1', option: "!configure-darkmode", weight: 50}
101+
102+
103+ - !registryValue:
104+ path : ' HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce'
105+ value : ' RevisionWallpaperStartup'
106+ type : REG_SZ
107+ oobe : only
108+ data : ' cmd /c "%SystemRoot%\Web\Wallpaper\MeetRevision\WallpaperStartup.cmd"'
92109
93110 # Necessary to refresh start menu entries etc.
94111 - !appx: {operation: clearCache, name: '*Client.CBS*'}
@@ -102,7 +119,7 @@ actions:
102119
103120 # Apply micro patches via Revision Tool in order to avoid new playbook releases for minor changes
104121 - !run:
105- path : " %ProgramFiles(x86) %\\ Revision Tool"
122+ path : " %ProgramFiles%\\ Revision Tool"
106123 exe : " revitool.exe"
107124 args : " playbook-patches apply"
108125 wait : true
0 commit comments