Remove powertop & tlp

Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
2025-06-11 12:21:16 +01:00
parent adb09135ce
commit d43ca1c8c1
12 changed files with 9 additions and 44 deletions

View File

@@ -0,0 +1,4 @@
{ ... }:
{
powerManagement.enable = true;
}

View File

@@ -1,6 +0,0 @@
{ pkgs, ... }:
{
environment.systemPackages = with pkgs; [ powertop ];
powerManagement.powertop.enable = true;
systemd.services.powertop.postStart = builtins.readFile ./mouse.sh;
}

View File

@@ -1,16 +0,0 @@
# shellcheck shell=bash
SEARCH_STRINGS=(
"Mouse"
"Razer DeathAdder V3 HyperSpeed"
)
for search_string in "${SEARCH_STRINGS[@]}"; do
echo "Searching for devices matching: $search_string"
grep -l "$search_string" /sys/bus/usb/devices/*/product 2>/dev/null | sed "s/product/power\\/control/" | while IFS= read -r device
do
echo "Setting power control to 'on' for: $device"
echo on >| "$device"
done
done

View File

@@ -1,12 +0,0 @@
{ ... }:
{
services.tlp = {
enable = true;
settings = {
CPU_SCALING_GOVERNOR_ON_AC = "performance";
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
};
};
}