fixup! fixup! fixup! fixup! fixup! Inaho: new host
This commit is contained in:
@@ -53,7 +53,7 @@
|
|||||||
# Preserve batteries when the laptop is usually on AC.
|
# Preserve batteries when the laptop is usually on AC.
|
||||||
# Raise STOP_* to 100 if maximum autonomy matters more than battery wear.
|
# Raise STOP_* to 100 if maximum autonomy matters more than battery wear.
|
||||||
START_CHARGE_THRESH_BAT0 = 70;
|
START_CHARGE_THRESH_BAT0 = 70;
|
||||||
STOP_CHARGE_THRESH_BAT0 = 85;
|
STOP_CHARGE_THRESH_BAT0 = 95;
|
||||||
START_CHARGE_THRESH_BAT1 = 70;
|
START_CHARGE_THRESH_BAT1 = 70;
|
||||||
STOP_CHARGE_THRESH_BAT1 = 85;
|
STOP_CHARGE_THRESH_BAT1 = 85;
|
||||||
RESTORE_THRESHOLDS_ON_BAT = 1;
|
RESTORE_THRESHOLDS_ON_BAT = 1;
|
||||||
|
|||||||
@@ -3,13 +3,16 @@
|
|||||||
playerctl
|
playerctl
|
||||||
cava
|
cava
|
||||||
pulsemixer
|
pulsemixer
|
||||||
|
libnotify
|
||||||
|
|
||||||
monocraft
|
monocraft
|
||||||
font-awesome
|
font-awesome
|
||||||
nerd-fonts.symbols-only
|
nerd-fonts.symbols-only
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.waybar = {
|
programs.waybar = let
|
||||||
|
multibat = osConfig.networking.hostName == "Inaho";
|
||||||
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
systemd.enable = true;
|
systemd.enable = true;
|
||||||
|
|
||||||
@@ -31,7 +34,7 @@
|
|||||||
"tray"
|
"tray"
|
||||||
"group/system"
|
"group/system"
|
||||||
"pulseaudio"
|
"pulseaudio"
|
||||||
"battery"
|
( if multibat then "group/bat" else "battery" )
|
||||||
"clock"
|
"clock"
|
||||||
];
|
];
|
||||||
|
|
||||||
@@ -71,6 +74,19 @@
|
|||||||
dynamic-order = [ "title" "artist" "album" ];
|
dynamic-order = [ "title" "artist" "album" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
"group/bat" = lib.mkIf multibat {
|
||||||
|
orientation = "inherit";
|
||||||
|
drawer = {
|
||||||
|
transition-duration = 500;
|
||||||
|
transition-left-to-right = false;
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
"battery"
|
||||||
|
"battery#int"
|
||||||
|
"battery#ext"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
battery = {
|
battery = {
|
||||||
interval = 5;
|
interval = 5;
|
||||||
states = {
|
states = {
|
||||||
@@ -82,6 +98,33 @@
|
|||||||
default = ["" "" "" "" "" "" "" "" "" "" ""];
|
default = ["" "" "" "" "" "" "" "" "" "" ""];
|
||||||
charging = ["" "" "" "" "" "" "" "" "" "" ""];
|
charging = ["" "" "" "" "" "" "" "" "" "" ""];
|
||||||
};
|
};
|
||||||
|
events = {
|
||||||
|
on-discharging-warning = "notify-send -u normal 'Low Battery'";
|
||||||
|
on-discharging-critical = "notify-send -u critical 'Very Low Battery'";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
"battery#int" = lib.mkIf multibat {
|
||||||
|
bat = "BAT0";
|
||||||
|
interval = 5;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "I: {capacity}%";
|
||||||
|
};
|
||||||
|
|
||||||
|
"battery#ext" = lib.mkIf multibat {
|
||||||
|
bat = "BAT1";
|
||||||
|
interval = 5;
|
||||||
|
states = {
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "E: {capacity}%";
|
||||||
|
events = {
|
||||||
|
on-discharging-0 = "notify-send -u normal 'External battery died'";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
"keyboard-state" = {
|
"keyboard-state" = {
|
||||||
@@ -249,8 +292,9 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#system .drawer-child > * {
|
#system,
|
||||||
margin-right: 4px
|
#bat {
|
||||||
|
& .drawer-child > * { margin-right: 4px }
|
||||||
}
|
}
|
||||||
|
|
||||||
#keyboard-state label.locked {
|
#keyboard-state label.locked {
|
||||||
@@ -259,7 +303,6 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
#battery {
|
#battery {
|
||||||
&.plugged { color: ${colors.base0D}; }
|
|
||||||
&.charging { color: ${accent}; }
|
&.charging { color: ${accent}; }
|
||||||
&:not(.charging) {
|
&:not(.charging) {
|
||||||
&.warning {
|
&.warning {
|
||||||
@@ -280,6 +323,10 @@
|
|||||||
color: ${colors.base00};
|
color: ${colors.base00};
|
||||||
background: ${accent};
|
background: ${accent};
|
||||||
}
|
}
|
||||||
|
&.plugged {
|
||||||
|
color: ${colors.base00};
|
||||||
|
background: ${colors.base0D};
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes blink {
|
@keyframes blink {
|
||||||
|
|||||||
Reference in New Issue
Block a user