Remove powertop & tlp
Signed-off-by: Nikolaos Karaolidis <nick@karaolidis.com>
This commit is contained in:
4
hosts/common/configs/system/power/default.nix
Normal file
4
hosts/common/configs/system/power/default.nix
Normal file
@@ -0,0 +1,4 @@
|
||||
{ ... }:
|
||||
{
|
||||
powerManagement.enable = true;
|
||||
}
|
@@ -1,6 +0,0 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
environment.systemPackages = with pkgs; [ powertop ];
|
||||
powerManagement.powertop.enable = true;
|
||||
systemd.services.powertop.postStart = builtins.readFile ./mouse.sh;
|
||||
}
|
@@ -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
|
@@ -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";
|
||||
};
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user