cleanup
This commit is contained in:
parent
ed160b8280
commit
af09e1e1f9
6
etcnixos/flake.lock
generated
6
etcnixos/flake.lock
generated
@ -294,11 +294,11 @@
|
||||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1738638143,
|
||||
"narHash": "sha256-ZYMe4c4OCtIUBn5hx15PEGr0+B1cNEpl2dsaLxwY2W0=",
|
||||
"lastModified": 1738815599,
|
||||
"narHash": "sha256-gpDGrlNANp8+Ag7oAHiXtUIJ1kWHqTN/6G686PpkNl0=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "9bdd53f5908453e4d03f395eb1615c3e9a351f70",
|
||||
"rev": "d1f201fc627098d764ed00f736864ce673f5975e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
||||
@ -2,21 +2,32 @@
|
||||
{
|
||||
systemd.services.no-rgb =
|
||||
let
|
||||
no-rgb = pkgs.writeScriptBin "no-rgb" ''
|
||||
no-rgb = (
|
||||
pkgs.writeShellApplication {
|
||||
name = "no-rgb";
|
||||
runtimeInputs = with pkgs; [
|
||||
openrgb
|
||||
coreutils
|
||||
gnugrep
|
||||
];
|
||||
|
||||
text = ''
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
NUM_DEVICES=$(${pkgs.openrgb}/bin/openrgb --noautoconnect --list-devices | ${pkgs.gnugrep}/bin/grep -E '^[0-9]+: ' | ${pkgs.coreutils}/bin/wc -l)
|
||||
NUM_DEVICES=$(openrgb --noautoconnect --list-devices | grep -cE '^[0-9]+: ')
|
||||
|
||||
for i in $(${pkgs.coreutils}/bin/seq 0 $(($NUM_DEVICES - 1))); do
|
||||
${pkgs.openrgb}/bin/openrgb --noautoconnect --device $i --mode direct --color 000000
|
||||
for i in $(seq 0 $((NUM_DEVICES - 1))); do
|
||||
openrgb --noautoconnect --device "$i" --mode direct --color 000000
|
||||
done
|
||||
'';
|
||||
}
|
||||
);
|
||||
in
|
||||
{
|
||||
description = "disable rgb";
|
||||
serviceConfig = {
|
||||
ExecStart = "${no-rgb}/bin/no-rgb";
|
||||
ExecStart = "${no-rgb}/bin/${no-rgb.name}";
|
||||
Type = "oneshot";
|
||||
};
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
@ -29,5 +40,4 @@
|
||||
environment.systemPackages = with pkgs; [
|
||||
openrgb-with-all-plugins
|
||||
];
|
||||
|
||||
}
|
||||
|
||||
@ -86,8 +86,8 @@
|
||||
enable = true;
|
||||
capSysNice = true;
|
||||
};
|
||||
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
gamescopeSession.enable = true;
|
||||
};
|
||||
|
||||
@ -116,17 +116,11 @@
|
||||
#!/bin/sh
|
||||
rm -fr ${config.boot.lanzaboote.pkiBundle} || true
|
||||
mkdir -p ${config.boot.lanzaboote.pkiBundle}
|
||||
${pkgs.gnutar}/bin/tar xf /etc/nixos/secrets/secureboot.tar -C ${config.boot.lanzaboote.pkiBundle}
|
||||
${pkgs.gnutar}/bin/tar xf ${./secrets/secureboot.tar} -C ${config.boot.lanzaboote.pkiBundle}
|
||||
'';
|
||||
};
|
||||
|
||||
# https://github.com/NixOS/nixos-hardware/pull/1253
|
||||
# hardware.framework.laptop13.audioEnhancement = {
|
||||
# enable = true;
|
||||
# };i
|
||||
|
||||
# disable framework kernel module
|
||||
# https://github.com/NixOS/nixos-hardware/issues/1330
|
||||
|
||||
hardware.framework.enableKmod = false;
|
||||
}
|
||||
|
||||
@ -39,18 +39,18 @@
|
||||
|
||||
(defwidget window-title []
|
||||
(label
|
||||
:text "${windowtitle == "" ? "" : "(${windowtitle})"}"))
|
||||
:text {windowtitle == "" ? "" : "(${windowtitle})"}))
|
||||
|
||||
(defwidget brightness-ctl []
|
||||
(box :visible brightnessctl-open
|
||||
(cmd-slider :symbol "" :value brightness
|
||||
:command `brightnessctl set {}%`
|
||||
:max 101 :color "${
|
||||
:max 101 :color {
|
||||
brightness >= 80 ? "green" :
|
||||
brightness >= 50 ? "yellow" :
|
||||
brightness >= 30 ? "peach" :
|
||||
brightness >= 10 ? "maroon" : "red"
|
||||
}")))
|
||||
})))
|
||||
|
||||
|
||||
(defpoll brightness :interval "1s" :run-while brightnessctl-open `brightnessctl -m | awk -F, '{print $4+0}'`)
|
||||
@ -105,7 +105,7 @@
|
||||
(box :space-evenly false
|
||||
:tooltip powerstats
|
||||
(label
|
||||
:text "${EWW_BATTERY.BAT1.status == "Charging" ? "" :
|
||||
:text {EWW_BATTERY.BAT1.status == "Charging" ? "" :
|
||||
EWW_BATTERY.BAT1.capacity >= 90 ? "" :
|
||||
EWW_BATTERY.BAT1.capacity >= 80 ? "" :
|
||||
EWW_BATTERY.BAT1.capacity >= 70 ? "" :
|
||||
@ -115,13 +115,13 @@
|
||||
EWW_BATTERY.BAT1.capacity >= 30 ? "" :
|
||||
EWW_BATTERY.BAT1.capacity >= 20 ? "" :
|
||||
EWW_BATTERY.BAT1.capacity >= 10 ? "" : ""
|
||||
} "
|
||||
:class "${
|
||||
}
|
||||
:class {
|
||||
EWW_BATTERY.BAT1.capacity >= 80 ? "green" :
|
||||
EWW_BATTERY.BAT1.capacity >= 50 ? "yellow" :
|
||||
EWW_BATTERY.BAT1.capacity >= 30 ? "peach" :
|
||||
EWW_BATTERY.BAT1.capacity >= 10 ? "maroon" : "red"
|
||||
}")
|
||||
})
|
||||
(label :text "${EWW_BATTERY.BAT1.capacity}%" :class "yellow")))
|
||||
|
||||
|
||||
@ -131,7 +131,7 @@
|
||||
(defwidget volume []
|
||||
(eventbox :tooltip volumesink
|
||||
:onclick `pwvucontrol &`
|
||||
(label :text "${volumevalue.count}%" :class "${volumevalue.color}")))
|
||||
(label :text "${volumevalue.count}%" :class {volumevalue.color})))
|
||||
|
||||
|
||||
(defpoll currentworkspace :interval "1s" `scripts/currentWorkspace.fish`)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user