configuration.nix/home/gui/waybar-settings.nix
Jalil David Salamé Messina a449d9041d
All checks were successful
/ check (push) Successful in 46s
/ build (audiomenu) (push) Successful in 2s
/ build (docs) (push) Successful in 2s
/ build (jpassmenu) (push) Successful in 2s
/ build (nixosConfigurations.vm.config.system.build.toplevel) (push) Successful in 2s
/ build (nvim) (push) Successful in 2s
[chore] flake.lock: update inputs
Flake lock file updates:

• Updated input 'home-manager':
    'github:nix-community/home-manager/62d536255879be574ebfe9b87c4ac194febf47c5' (2024-12-01)
  → 'github:nix-community/home-manager/c7ffc9727d115e433fd884a62dc164b587ff651d' (2024-12-07)
• Updated input 'nixpkgs':
    'github:NixOS/nixpkgs/b681065d0919f7eb5309a93cea2cfa84dec9aa88' (2024-12-03)
  → 'github:NixOS/nixpkgs/4dc2fc4e62dbf62b84132fe526356fbac7b03541' (2024-12-05)
• Updated input 'nixvim':
    'github:nix-community/nixvim/6348336db0e0b17ab6d9c73bc8206db84ebf00d1' (2024-12-05)
  → 'github:nix-community/nixvim/08be20270d62e31f215f4592867d53576af15001' (2024-12-07)
• Updated input 'unstable':
    'github:NixOS/nixpkgs/55d15ad12a74eb7d4646254e13638ad0c4128776' (2024-12-03)
  → 'github:NixOS/nixpkgs/d0797a04b81caeae77bcff10a9dde78bc17f5661' (2024-12-05)
2024-12-08 14:07:57 +01:00

127 lines
2.8 KiB
Nix

{ config, lib }:
let
cfg = config.jhome.gui;
in
{
mainBar = {
layer = "top";
position = "top";
margin = "2 2 2 2";
# Choose the order of the modules
modules-left = [ "sway/workspaces" ];
modules-center = [ "clock" ];
modules-right =
[
"pulseaudio"
"backlight"
"battery"
"sway/language"
"memory"
]
++ lib.optional (cfg.tempInfo != null) "temperature"
++ [ "tray" ];
"sway/workspaces" = {
disable-scroll = true;
persistent-workspaces = {
"1" = [ ];
"2" = [ ];
"3" = [ ];
"4" = [ ];
"5" = [ ];
"6" = [ ];
"7" = [ ];
"8" = [ ];
"9" = [ ];
};
};
"sway/language" = {
format = "{} ";
min-length = 5;
tooltip = false;
};
memory = {
format = "{used:0.1f}/{total:0.1f}GiB ";
interval = 3;
};
clock = {
timezone = "Europe/Berlin";
tooltip-format = "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>";
format = "{:%a, %d %b, %H:%M}";
};
pulseaudio = {
reverse-scrolling = 1;
format = "{volume}% {icon} {format_source}";
format-bluetooth = "{volume}% {icon} {format_source}";
format-bluetooth-muted = "{volume}% 󰖁 {icon} {format_source}";
format-muted = "{volume}% 󰖁 {format_source}";
format-source = "{volume}% ";
format-source-muted = "{volume}% 󰍭";
format-icons = {
headphone = "󰋋";
hands-free = "";
headset = "󰋎";
phone = "󰘂";
portable = "";
car = "";
default = [
"󰕿"
"󰖀"
"󰕾"
];
};
on-click = "pavucontrol";
min-length = 13;
};
temperature = lib.optionalAttrs (cfg.tempInfo != null) {
inherit (cfg.tempInfo) hwmon-path;
critical-threshold = 80;
format = "{temperatureC}°C {icon}";
format-icons = [
""
""
""
""
""
];
tooltip = false;
};
backlight = {
device = "intel_backlight";
format = "{percent}% {icon}";
format-icons = [
"󰃚"
"󰃛"
"󰃜"
"󰃝"
"󰃞"
"󰃟"
"󰃠"
];
min-length = 7;
};
battery = {
states.warning = 30;
states.critical = 15;
format = "{capacity}% {icon}";
format-charging = "{capacity}% 󰂄";
format-plugged = "{capacity}% 󰚥";
format-alt = "{time} {icon}";
format-icons = [
"󰁺"
"󰁻"
"󰁼"
"󰁽"
"󰁾"
"󰁿"
"󰂀"
"󰂁"
"󰂂"
"󰁹"
];
};
tray = {
icon-size = 16;
spacing = 0;
};
};
}