Skip to content

Commit

Permalink
Restore Sleep Button (#158)
Browse files Browse the repository at this point in the history
- Also restoring the default Hibernate type (Full)
  • Loading branch information
LeDragoX committed May 14, 2024
1 parent 7346493 commit 2fb7bb5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/scripts/Optimize-Performance.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ function Optimize-Performance() {
powercfg -DuplicateScheme e9a42b02-d5df-448d-aa00-03f14749eb61
Write-Host
Unregister-DuplicatedPowerPlan
Enable-Hibernate -Type 'Reduced'
Enable-Hibernate -Type 'Full'

Write-Section "Network & Internet"
Write-Status -Types "+", $TweakType -Status "Unlimiting your network bandwidth for all your system..." # Based on this Chris Titus video: https://youtu.be/7u1miYJmJ_4
Expand Down
3 changes: 3 additions & 0 deletions src/utils/Individual-Tweaks.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,9 @@ function Enable-Hibernate() {
# Full = Enables Hibernate power button and Fast Startup | Reduced = Enable Fast Startup only
Write-Status -Types "+", "Performance" -Status "Setting Hibernate size to $Type..."
powercfg -Hibernate -Type $Type | Out-Host

Write-Status -Types "+", "Performance" -Status "Restoring the Sleep Button at the Start Menu..."
Set-ItemPropertyVerified -Path "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FlyoutMenuSettings " -Name "ShowSleepOption" -Type DWord -Value 1
}

function Disable-HyperV() {
Expand Down

0 comments on commit 2fb7bb5

Please sign in to comment.