Skip to content

Instantly share code, notes, and snippets.

@tpgone
tpgone / Unlock-PowerCfg.ps1
Created August 28, 2021 04:45 — forked from Velocet/Unlock-PowerCfg.ps1
[win] Unlock every Power Plan & Option
#Requires -RunAsAdministrator
if (!$IsLinux -and !$IsMacOS) {
# Unlock Power Plans by disabling "Connected Standby"
Set-ItemProperty -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\Power' -Name 'CSEnabled' -Value 0 -Force
# Unlock hidden options
$PowerSettings = Get-ChildItem -Path 'HKLM:\SYSTEM\CurrentControlSet\Control\Power\PowerSettings' -Recurse -Depth 1 | Where-Object { $_.PSChildName -NotLike 'DefaultPowerSchemeValues' -and $_.PSChildName -NotLike '0' -and $_.PSChildName -NotLike '1' }
ForEach ($item in $PowerSettings) { Set-ItemProperty -Path ($item).Replace('HKEY_LOCAL_MACHINE','HKLM:') -Name 'Attributes' -Value 2 -Force }
}
@tpgone
tpgone / tlrecode.sh
Created August 5, 2021 07:29 — forked from NikitaKarnauhov/tlrecode.sh
Shell script to decode and encode TP-LINK router config files
#!/usr/bin/env bash
# tlrecode.sh
# Decode and encode TP-LINK router config files.
#
# Creative Commons CC0 License:
# http://creativecommons.org/publicdomain/zero/1.0/
#
# To the extent possible under law, the person who associated CC0 with this
# work has waived all copyright and related or neighboring rights to this work.
@tpgone
tpgone / list.md
Created June 16, 2021 14:03 — forked from ih2502mk/list.md
Quantopian Lectures Saved