First base waybar rice
This commit is contained in:
@@ -18,6 +18,7 @@
|
|||||||
./stylix.nix
|
./stylix.nix
|
||||||
./vscode.nix
|
./vscode.nix
|
||||||
./wallpaper.nix
|
./wallpaper.nix
|
||||||
|
./waybar
|
||||||
./wlogout.nix
|
./wlogout.nix
|
||||||
./xdg.nix
|
./xdg.nix
|
||||||
./yazi.nix
|
./yazi.nix
|
||||||
|
|||||||
@@ -5,7 +5,6 @@
|
|||||||
}:
|
}:
|
||||||
{
|
{
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
waybar
|
|
||||||
hyprpolkitagent
|
hyprpolkitagent
|
||||||
];
|
];
|
||||||
|
|
||||||
@@ -39,7 +38,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
exec-once = [
|
exec-once = [
|
||||||
"systemctl --user enable --now waybar.service"
|
|
||||||
"systemctl --user enable --now hyprpolkitagent.service"
|
"systemctl --user enable --now hyprpolkitagent.service"
|
||||||
"wpaperd -d"
|
"wpaperd -d"
|
||||||
"systemctl enable --user app-com.mitchellh.ghostty.service"
|
"systemctl enable --user app-com.mitchellh.ghostty.service"
|
||||||
|
|||||||
343
modules/home/waybar/default.nix
Normal file
343
modules/home/waybar/default.nix
Normal file
@@ -0,0 +1,343 @@
|
|||||||
|
{
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
let
|
||||||
|
hyprland-workspaces = {
|
||||||
|
format = "{icon}";
|
||||||
|
show-special = false;
|
||||||
|
active-only = false;
|
||||||
|
on-click = "activate";
|
||||||
|
on-scroll-up = "hyprctl dispatch workspace e+1";
|
||||||
|
on-scroll-down = "hyprctl dispatch workspace e-1";
|
||||||
|
all-outputs = true;
|
||||||
|
sort-by-number = true;
|
||||||
|
persistent-workspaces = {
|
||||||
|
"1" = [ ];
|
||||||
|
"2" = [ ];
|
||||||
|
"3" = [ ];
|
||||||
|
"4" = [ ];
|
||||||
|
};
|
||||||
|
format-icons = {
|
||||||
|
"1" = " ";
|
||||||
|
"2" = " ";
|
||||||
|
"3" = " ";
|
||||||
|
"4" = " ";
|
||||||
|
"5" = "";
|
||||||
|
"6" = " ";
|
||||||
|
"7" = "";
|
||||||
|
"8" = " ";
|
||||||
|
"9" = " ";
|
||||||
|
"10" = "10";
|
||||||
|
"focused" = "";
|
||||||
|
"default" = "";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
menu = {
|
||||||
|
format = "{}";
|
||||||
|
exec = "echo ; echo app launcher";
|
||||||
|
interval = 86400;
|
||||||
|
tooltip = true;
|
||||||
|
on-click = "pkill rofi || rofi -show drun -show-icons";
|
||||||
|
};
|
||||||
|
|
||||||
|
hyprland-window = {
|
||||||
|
format = " {title}";
|
||||||
|
max-length = 40;
|
||||||
|
separate-outputs = false;
|
||||||
|
rewrite = {
|
||||||
|
"^.*( — LibreWolf|LibreWolf)$" = " LibreWolf";
|
||||||
|
"(.*) — Mozilla Firefox" = " Firefox";
|
||||||
|
"^.*v( .*|$)" = " Neovim";
|
||||||
|
"^.*~$" = " Kitty";
|
||||||
|
"(.*) " = " Empty";
|
||||||
|
"^.*pdf( .*|$)" = "";
|
||||||
|
"^.*(- Mousepad)$" = " $1";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
arrow-right = {
|
||||||
|
format = "";
|
||||||
|
tooltip = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
cpu = {
|
||||||
|
format = " {usage}";
|
||||||
|
};
|
||||||
|
|
||||||
|
memory = {
|
||||||
|
interval = 10;
|
||||||
|
format = "{used:0.1f}G ";
|
||||||
|
format-alt = "{percentage}% ";
|
||||||
|
format-alt-click = "click";
|
||||||
|
tooltip = true;
|
||||||
|
tooltip-format = "{used:0.1f}GB/{total:0.1f}G";
|
||||||
|
# on-click-right = "kitty --title btop sh -c 'btop'";
|
||||||
|
};
|
||||||
|
|
||||||
|
temperature = {
|
||||||
|
interval = 10;
|
||||||
|
tooltip = true;
|
||||||
|
hwmon-path = [
|
||||||
|
"/sys/class/hwmon/hwmon6/temp1_input"
|
||||||
|
"/sys/class/thermal/thermal_zone0/temp"
|
||||||
|
];
|
||||||
|
critical-threshold = 82;
|
||||||
|
format-critical = "{temperatureC}°C {icon}";
|
||||||
|
format = "{temperatureC}°C {icon}";
|
||||||
|
format-icons = [ "" ];
|
||||||
|
# on-click-right = "kitty --title nvtop sh -c 'nvtop'";
|
||||||
|
};
|
||||||
|
|
||||||
|
idle-inhibitor = {
|
||||||
|
format = "{icon}";
|
||||||
|
format-icons = {
|
||||||
|
activated = " ";
|
||||||
|
deactivated = " ";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
tray = {
|
||||||
|
icon-size = 16;
|
||||||
|
spacing = 4;
|
||||||
|
};
|
||||||
|
|
||||||
|
pulseaudio = {
|
||||||
|
format = "{icon} {volume}%";
|
||||||
|
format-bluetooth = "{icon} {volume}";
|
||||||
|
format-muted = "";
|
||||||
|
format-icons = {
|
||||||
|
headphone = "";
|
||||||
|
hands-free = "";
|
||||||
|
headset = "";
|
||||||
|
phone = "";
|
||||||
|
portable = "";
|
||||||
|
car = "";
|
||||||
|
default = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
ignored-sinks = [ "Easy Effects Sink" ];
|
||||||
|
};
|
||||||
|
scroll-step = 5.0;
|
||||||
|
# on-click-right = "pavucontrol -t 3";
|
||||||
|
tooltip-format = "{icon} {desc} | {volume}%";
|
||||||
|
smooth-scrolling-threshold = 1;
|
||||||
|
};
|
||||||
|
|
||||||
|
battery = {
|
||||||
|
align = 0;
|
||||||
|
rotate = 0;
|
||||||
|
full-at = 100;
|
||||||
|
design-capacity = false;
|
||||||
|
states = {
|
||||||
|
good = 95;
|
||||||
|
warning = 30;
|
||||||
|
critical = 15;
|
||||||
|
};
|
||||||
|
format = "{icon} {capacity}";
|
||||||
|
format-charging = " {capacity}%";
|
||||||
|
format-plugged = " {capacity}%";
|
||||||
|
format-alt-click = "click";
|
||||||
|
format-full = "{icon} Full";
|
||||||
|
format-alt = "{icon} {time}";
|
||||||
|
format-icons = [
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
""
|
||||||
|
];
|
||||||
|
format-time = "{H}h {M}min";
|
||||||
|
tooltip = true;
|
||||||
|
tooltip-format = "{timeTo} {power}w";
|
||||||
|
};
|
||||||
|
|
||||||
|
mpris = {
|
||||||
|
interval = 10;
|
||||||
|
format = "{player_icon} ";
|
||||||
|
format-paused = "{status_icon}";
|
||||||
|
on-click-middle = "playerctl play-pause";
|
||||||
|
on-click = "playerctl previous";
|
||||||
|
on-click-right = "playerctl next";
|
||||||
|
scroll-step = 5.0;
|
||||||
|
smooth-scrolling-threshold = 1;
|
||||||
|
player-icons = {
|
||||||
|
chromium = "";
|
||||||
|
mpd = "";
|
||||||
|
default = "";
|
||||||
|
firefox = "";
|
||||||
|
kdeconnect = "";
|
||||||
|
mopidy = "";
|
||||||
|
mpv = "";
|
||||||
|
spotify = "";
|
||||||
|
vlc = "";
|
||||||
|
};
|
||||||
|
status-icons = {
|
||||||
|
paused = "";
|
||||||
|
playing = "";
|
||||||
|
stopped = "";
|
||||||
|
};
|
||||||
|
max-length = 10;
|
||||||
|
};
|
||||||
|
|
||||||
|
arrow-left = {
|
||||||
|
format = "";
|
||||||
|
tooltip = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
notifications = {
|
||||||
|
tooltip = false;
|
||||||
|
format = "{icon} {text}";
|
||||||
|
format-icons = {
|
||||||
|
notification = "";
|
||||||
|
none = "";
|
||||||
|
dnd-notification = "";
|
||||||
|
dnd-none = "";
|
||||||
|
inhibited-notification = "";
|
||||||
|
inhibited-none = "";
|
||||||
|
dnd-inhibited-notification = "";
|
||||||
|
dnd-inhibited-none = "";
|
||||||
|
};
|
||||||
|
return-type = "json";
|
||||||
|
# exec-if = "which swaync-client";
|
||||||
|
# exec = "swaync-client -swb";
|
||||||
|
# on-click = "swaync-client -t -sw";
|
||||||
|
# on-click-right = "swaync-client -d -sw";
|
||||||
|
escape = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
clock = {
|
||||||
|
interval = 1;
|
||||||
|
format = "{:%I:%M %p}"; # AM-PM Format
|
||||||
|
format-alt = " {:%H:%M %Y, %d %B, %A}";
|
||||||
|
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
||||||
|
calendar = {
|
||||||
|
mode = "year";
|
||||||
|
mode-mon-col = 3;
|
||||||
|
weeks-pos = "right";
|
||||||
|
on-scroll = 1;
|
||||||
|
format = {
|
||||||
|
months = "<span color='#ffead3'><b>{}</b></span>";
|
||||||
|
days = "<span color='#ecc6d9'><b>{}</b></span>";
|
||||||
|
weeks = "<span color='#99ffdd'><b>W{}</b></span>";
|
||||||
|
weekdays = "<span color='#ffcc66'><b>{}</b></span>";
|
||||||
|
today = "<span color='#ff6699'><b><u>{}</u></b></span>";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
power = {
|
||||||
|
format = "⏻";
|
||||||
|
exec = "echo ; echo power";
|
||||||
|
on-click = "wlogout";
|
||||||
|
interval = 86400;
|
||||||
|
tooltip = true;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
programs.waybar = {
|
||||||
|
enable = true;
|
||||||
|
systemd.enable = true;
|
||||||
|
settings = [
|
||||||
|
{
|
||||||
|
layer = "top";
|
||||||
|
position = "top";
|
||||||
|
height = 34;
|
||||||
|
width = 1200;
|
||||||
|
margin-left = 50;
|
||||||
|
margin-right = 50;
|
||||||
|
margin-top = 5;
|
||||||
|
fixed-center = true;
|
||||||
|
reload_style_on_change = true;
|
||||||
|
|
||||||
|
modules-left = [
|
||||||
|
"custom/menu"
|
||||||
|
"hyprland/window"
|
||||||
|
"group/info"
|
||||||
|
];
|
||||||
|
|
||||||
|
modules-center = [
|
||||||
|
"hyprland/workspaces#4"
|
||||||
|
];
|
||||||
|
|
||||||
|
modules-right = [
|
||||||
|
"idle_inhibitor"
|
||||||
|
"group/demo"
|
||||||
|
"group/hub"
|
||||||
|
];
|
||||||
|
|
||||||
|
"hyprland/workspaces#4" = hyprland-workspaces;
|
||||||
|
"custom/menu" = menu;
|
||||||
|
"hyprland/window" = hyprland-window;
|
||||||
|
"custom/arrow-right" = arrow-right;
|
||||||
|
"cpu" = cpu;
|
||||||
|
"memory" = memory;
|
||||||
|
"temperature" = temperature;
|
||||||
|
"idle_inhibitor" = idle-inhibitor;
|
||||||
|
"tray" = tray;
|
||||||
|
"pulseaudio" = pulseaudio;
|
||||||
|
"mpris" = mpris;
|
||||||
|
"battery" = battery;
|
||||||
|
"custom/arrow-left" = arrow-left;
|
||||||
|
"custom/notifications" = notifications;
|
||||||
|
"clock" = clock;
|
||||||
|
"custom/power" = power;
|
||||||
|
|
||||||
|
"group/info" = {
|
||||||
|
orientation = "inherit";
|
||||||
|
drawer = {
|
||||||
|
transition-duration = 300;
|
||||||
|
transition-left-to-right = false;
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
"custom/arrow-right"
|
||||||
|
"cpu"
|
||||||
|
"memory"
|
||||||
|
"temperature"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"group/demo" = {
|
||||||
|
orientation = "inherit";
|
||||||
|
modules = [
|
||||||
|
"tray"
|
||||||
|
"pulseaudio"
|
||||||
|
"mpris"
|
||||||
|
"battery"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"group/utils" = {
|
||||||
|
orientation = "inherit";
|
||||||
|
drawer = {
|
||||||
|
transition-duration = 300;
|
||||||
|
transition-left-to-right = true;
|
||||||
|
};
|
||||||
|
modules = [
|
||||||
|
"custom/arrow-left"
|
||||||
|
"custom/notifications"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"group/hub" = {
|
||||||
|
orientation = "inherit";
|
||||||
|
modules = [
|
||||||
|
"group/utils"
|
||||||
|
"clock"
|
||||||
|
"custom/power"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
style = ./style.css;
|
||||||
|
};
|
||||||
|
}
|
||||||
184
modules/home/waybar/style.css
Normal file
184
modules/home/waybar/style.css
Normal file
@@ -0,0 +1,184 @@
|
|||||||
|
@define-color foreground #BFE3EA;
|
||||||
|
@define-color background alpha(#000007,0.05);
|
||||||
|
@define-color cursor #B98FAE;
|
||||||
|
|
||||||
|
@define-color color0 #000009;
|
||||||
|
@define-color color1 #60697E;
|
||||||
|
@define-color color2 #BA4F80;
|
||||||
|
@define-color color3 #4F7F96;
|
||||||
|
@define-color color4 #BE869D;
|
||||||
|
@define-color color5 #47A6BD;
|
||||||
|
@define-color color6 #49AEC4;
|
||||||
|
@define-color color7 #9BCED9;
|
||||||
|
@define-color color8 #6D9098;
|
||||||
|
@define-color color9 #60697E;
|
||||||
|
@define-color color10 #BA4F80;
|
||||||
|
@define-color color11 #4F7F96;
|
||||||
|
@define-color color12 #BE869D;
|
||||||
|
@define-color color13 #47A6BD;
|
||||||
|
@define-color color14 #49AEC4;
|
||||||
|
@define-color color15 #9BCED9;
|
||||||
|
|
||||||
|
/* ---- 💫 https://github.com/JaKooLit 💫 ---- */
|
||||||
|
/*DARK_PURPLE*/
|
||||||
|
|
||||||
|
@define-color main-color @color15;
|
||||||
|
* {
|
||||||
|
all: unset; /*this is really important to isolate waybar from gtk*/
|
||||||
|
font: bold 14px "FiraCode Nerd Font";
|
||||||
|
font-feature-settings: '"zero", "ss01", "ss02", "ss03", "ss04", "ss05", "cv31"';
|
||||||
|
border: none;
|
||||||
|
|
||||||
|
border-radius: 0;
|
||||||
|
box-shadow: none;
|
||||||
|
text-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
window#waybar {
|
||||||
|
/*background: alpha(@background, 0.1);*/
|
||||||
|
background: rgba (0, 0, 0, 0.6);
|
||||||
|
border-radius: 5px;
|
||||||
|
/*border: 0px solid alpha(@background,0.8);*/
|
||||||
|
}
|
||||||
|
|
||||||
|
#window {
|
||||||
|
padding: 0px 8px;
|
||||||
|
margin: 5px 4px 5px 4px;
|
||||||
|
background: alpha(@color12, 0.3);
|
||||||
|
border-radius: 5px;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
tooltip {
|
||||||
|
background: alpha(@background, 0.8);
|
||||||
|
border: 2px solid alpha(lighter(@main-color), 0.8);
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
tooltip label {
|
||||||
|
color: @freground;
|
||||||
|
}
|
||||||
|
|
||||||
|
#custom-arrow-right {
|
||||||
|
color: @main-color;
|
||||||
|
margin: 0px 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#cpu,
|
||||||
|
#memory,
|
||||||
|
#temperature,
|
||||||
|
#disk,
|
||||||
|
#custom-updates {
|
||||||
|
padding: 0px 6px;
|
||||||
|
margin: 6px 4px;
|
||||||
|
background: alpha(darker(@main-color), 0.4);
|
||||||
|
color: @main-color;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces {
|
||||||
|
margin: 4px 4px;
|
||||||
|
background: alpha(lighter(@color4), 0.09);
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button {
|
||||||
|
padding: 0px 4px;
|
||||||
|
margin: 0px 0px;
|
||||||
|
color: alpha(@foreground, 0.3);
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.active {
|
||||||
|
transition: color 0.5s;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.urgent,
|
||||||
|
#workspaces button:hover {
|
||||||
|
color: @color12;
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
#demo,
|
||||||
|
#control-center {
|
||||||
|
padding: 0px 6px;
|
||||||
|
margin: 4px 2px 4px 2px;
|
||||||
|
color: lighter(@color3);
|
||||||
|
background: alpha(lighter(@main-color), 0.08);
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#bluetooth,
|
||||||
|
#network,
|
||||||
|
#pulseaudio {
|
||||||
|
padding: 0px 0 0 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pulseaudio-slider slider {
|
||||||
|
min-height: 0px;
|
||||||
|
min-width: 0px;
|
||||||
|
background-color: transparent;
|
||||||
|
border: none;
|
||||||
|
box-shadow: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pulseaudio-slider {
|
||||||
|
margin: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#pulseaudio-slider highlight {
|
||||||
|
border-radius: 8px;
|
||||||
|
background-color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#language {
|
||||||
|
padding: 0px 3px 2px 0px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#custom-arrow-left {
|
||||||
|
color: lighter(@main-color);
|
||||||
|
margin: 0px 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#custom-notifications,
|
||||||
|
#custom-weather,
|
||||||
|
#custom-theme-switcher {
|
||||||
|
padding: 0px 8px;
|
||||||
|
margin: 8px 4px;
|
||||||
|
color: @main-color;
|
||||||
|
background: alpha(darker(@main-color), 0.8);
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
#tray {
|
||||||
|
padding: 0px 8px;
|
||||||
|
margin: 4px 2px 4px 2px;
|
||||||
|
background: alpha(@color12, 0.3);
|
||||||
|
border-radius: 5px;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#custom-menu,
|
||||||
|
#custom-power {
|
||||||
|
padding: 0px 10px 0px 6px;
|
||||||
|
margin: 6px 6px 6px 4px;
|
||||||
|
background: alpha(@color12, 0.3);
|
||||||
|
border-radius: 5px;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#clock {
|
||||||
|
padding: 0px 8px;
|
||||||
|
margin: 5px 2px 5px 4px;
|
||||||
|
background: alpha(@color12, 0.3);
|
||||||
|
border-radius: 5px;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#power,
|
||||||
|
#bluetooth,
|
||||||
|
#mpd,
|
||||||
|
#pulseaudio,
|
||||||
|
#battery,
|
||||||
|
#mpris {
|
||||||
|
padding: 4px 4px;
|
||||||
|
color: lighter(@main-color);
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user