diff options
Diffstat (limited to 'hosts/mercury/hjem.nix')
| -rw-r--r-- | hosts/mercury/hjem.nix | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/hosts/mercury/hjem.nix b/hosts/mercury/hjem.nix index 1e87ddd..afdf861 100644 --- a/hosts/mercury/hjem.nix +++ b/hosts/mercury/hjem.nix @@ -3,17 +3,14 @@ obsidian anki libreoffice-qt + musescore - kdePackages.kleopatra prismlauncher mpv + bluetuith opencode - musescore - vital - - bluetuith (pkgs.callPackage ../../pkgs/yo {}) captive-browser # https://words.filippo.io/captive-browser @@ -25,6 +22,13 @@ terminal = false; categories = ["Application"]; }) + + (pkgs.writeShellScriptBin "battery.sh" '' + energy_now=$(cat /sys/class/power_supply/BAT0/energy_now) + energy_full=$(cat /sys/class/power_supply/BAT0/energy_full) + percentage=$((energy_now * 100 / energy_full)) + printf "%.0f%%" "$percentage" + '') ]; files.".config/captive-browser.toml".text = '' |
