try to fix battery problems with the framework

This commit is contained in:
Ingolf Wagner 2023-08-04 00:43:27 +02:00
parent 95e908cb1d
commit 5fedc0b6c0
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B
2 changed files with 40 additions and 10 deletions

View file

@ -2,6 +2,10 @@
with lib; with lib;
let let
configuration = { configuration = {
# series
# ------
druck1 = { druck1 = {
url = "https://www.youtube.com/watch?list=PLUQncgYMM1RncxDFRfjkucPWRz5-8rjaH"; url = "https://www.youtube.com/watch?list=PLUQncgYMM1RncxDFRfjkucPWRz5-8rjaH";
target = "/media/youtube/series/Druck"; target = "/media/youtube/series/Druck";
@ -42,56 +46,69 @@ let
target = "/media/youtube/series/Druck"; target = "/media/youtube/series/Druck";
output = "Druck S08E%(playlist_index)s %(title)s.%(ext)s"; output = "Druck S08E%(playlist_index)s %(title)s.%(ext)s";
}; };
# channels
# --------
ordinary_things = { ordinary_things = {
url = "https://www.youtube.com/@OrdinaryThings"; url = "https://www.youtube.com/@OrdinaryThings";
target = "/media/youtube/series/Ordinary Things"; target = "/media/youtube/channels/Ordinary Things";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
internet_historian = { internet_historian = {
url = "https://www.youtube.com/@InternetHistorian"; url = "https://www.youtube.com/@InternetHistorian";
target = "/media/youtube/series/Internet Historian"; target = "/media/youtube/channels/Internet Historian";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
bigboss = { bigboss = {
url = "https://www.youtube.com/@bigbosstube"; url = "https://www.youtube.com/@bigbosstube";
target = "/media/youtube/series/Big Boss"; target = "/media/youtube/channels/Big Boss";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
CGPGrey = { CGPGrey = {
url = "https://www.youtube.com/@CGPGrey"; url = "https://www.youtube.com/@CGPGrey";
target = "/media/youtube/series/CGP Grey"; target = "/media/youtube/channels/CGP Grey";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
Joeseppi = { Joeseppi = {
url = "https://www.youtube.com/@Joeseppi"; url = "https://www.youtube.com/@Joeseppi";
target = "/media/youtube/series/Joeseppi"; target = "/media/youtube/channels/Joeseppi";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
HungrigerHugo = { HungrigerHugo = {
url = "https://www.youtube.com/@HungrigerHugo"; url = "https://www.youtube.com/@HungrigerHugo";
target = "/media/youtube/series/HungrigerHugo"; target = "/media/youtube/channels/HungrigerHugo";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
Kurzgesagt = { Kurzgesagt = {
url = "https://www.youtube.com/@KurzgesagtDE"; url = "https://www.youtube.com/@KurzgesagtDE";
target = "/media/youtube/series/Kurzgesagt"; target = "/media/youtube/channels/Kurzgesagt";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
Simplicissimus = { Simplicissimus = {
url = "https://www.youtube.com/@Simplicissimus"; url = "https://www.youtube.com/@Simplicissimus";
target = "/media/youtube/series/Simplicissimus"; target = "/media/youtube/channels/Simplicissimus";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
Soosenbinder = { Soosenbinder = {
url = "https://www.youtube.com/@Soosenbinder"; url = "https://www.youtube.com/@Soosenbinder";
target = "/media/youtube/series/Soosenbinder"; target = "/media/youtube/channels/Soosenbinder";
output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s"; output = "%(channel)s S%(upload_date>%Y)sE%(upload_date>%m%d)s %(title)s.%(ext)s";
}; };
SunkCostGalaxy = { SunkCostGalaxy = {
url = "https://www.youtube.com/watch?list=PL7SIP0NDfM2yyHKfRmCAociCcJKZHHY0E"; url = "https://www.youtube.com/watch?list=PL7SIP0NDfM2yyHKfRmCAociCcJKZHHY0E";
target = "/media/youtube/series/SunkCostGalaxy"; target = "/media/youtube/channels/SunkCostGalaxy";
output = "SunkCostGalaxy S01E%(playlist_index)s %(title)s.%(ext)s"; output = "SunkCostGalaxy S01E%(playlist_index)s %(title)s.%(ext)s";
}; };
AllGasNoBreaks = {
url = "https://www.youtube.com/@allgasnobrakes2491";
target = "/media/youtube/channels/SunkCostGalaxy";
output = "SunkCostGalaxy S01E%(playlist_index)s %(title)s.%(ext)s";
};
# My Playlists
# ------------
MusicVideos = { MusicVideos = {
url = "https://www.youtube.com/playlist?list=PLP33x-q_GftakJgpD48pZNl0TkhljQI7S"; url = "https://www.youtube.com/playlist?list=PLP33x-q_GftakJgpD48pZNl0TkhljQI7S";
target = "/media/youtube/music-videos"; target = "/media/youtube/music-videos";

View file

@ -46,6 +46,19 @@
services.flatpak.enable = true; services.flatpak.enable = true;
# make sure battery is charged in a way to live for a long time
services.power-profiles-daemon.enable = false;
services.tlp = {
enable = true;
settings = {
CPU_BOOST_ON_BAT = 0;
CPU_SCALING_GOVERNOR_ON_BATTERY = "powersave";
START_CHARGE_THRESH_BAT0 = 30;
STOP_CHARGE_THRESH_BAT0 = 85;
RUNTIME_PM_ON_BAT = "auto";
};
};
security.wrappers = { security.wrappers = {
pmount = { pmount = {
source = "${pkgs.pmount}/bin/pmount"; source = "${pkgs.pmount}/bin/pmount";