Files
winutil/functions/public/Invoke-WPFUltimatePerformance.ps1
T
Noah Webber d0f7689504 Kitchen sink changes (#5040)
* docs: fix typo in contributing image asset and markdown references

* docs: fix typos and grammatical phrasing in documentation

* fix(config): correct typographical errors in tweak and app descriptions

* fix(scripts): resolve typos and grammatical errors in PowerShell sources

* fix: address review feedback on Outlook description, WinUtil capitalization, and grammar
2026-09-02 10:14:51 -05:00

10 lines
517 B
PowerShell

function Invoke-WPFUltimatePerformance ([switch]$Enable) {
if ($Enable) {
powercfg /setactive (powercfg /duplicatescheme e9a42b02-d5df-448d-aa00-03f14749eb61 | Select-String -Pattern '[A-Fa-f0-9-]{36}').Matches.Value
[System.Windows.MessageBox]::Show("Ultimate Power Plan installed and activated.","Success","OK","Information")
} else {
powercfg /restoredefaultschemes
[System.Windows.MessageBox]::Show("Power Plan was reset to defaults.","Success","OK","Information")
}
}