WIP new top level flakes break down

This commit is contained in:
RingOfStorms (Joshua Bell) 2025-10-20 20:45:26 -05:00
parent 2238aaf367
commit 7215fd37bf
57 changed files with 3033 additions and 69 deletions

View file

@ -0,0 +1,15 @@
{ ... }:
{
imports = [
./theme.nix
./hyprland.nix
./hyprpaper.nix
# ./quickshell.nix
./waybar.nix
./hyprpolkitagent.nix
./wofi.nix
./swaync.nix
./scripts.nix
./swaylock.nix
];
}

View file

@ -0,0 +1,176 @@
{
osConfig,
lib,
hyprlandPkgs,
...
}:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
wayland.windowManager.hyprland = {
enable = true;
xwayland.enable = osConfig.programs.hyprland.xwayland.enable;
# plugins = with hyprlandPkgs.hyprlandPlugins; [
# hyprspace
# ];
settings = lib.attrsets.recursiveUpdate {
# Debug logs enabled when this is uncommented
debug.disable_logs = false;
debug.disable_time = false;
# exec-once = [ "pgrep waybar>/dev/null || waybar" ];
# Default monitor configuration
monitor = "monitor = , preferred, auto, 1";
windowrulev2 = [
# Bitwarden password manager popup for chrome, always float it
"float, class:^(?i)chrome-nngceckbapebfimnlniiiahkandclblb-Default$, initialtitle:^_crx_nngceckbapebfimnlniiiahkandclblb$"
"center, class:^(?i)chrome-nngceckbapebfimnlniiiahkandclblb-Default$, initialtitle:^_crx_nngceckbapebfimnlniiiahkandclblb$"
"size 720 600, class:^(?i)chrome-nngceckbapebfimnlniiiahkandclblb-Default$, initialtitle:^_crx_nngceckbapebfimnlniiiahkandclblb$"
];
# Input configuration
input = {
kb_layout = "us";
kb_options = "caps:escape";
follow_mouse = 2;
touchpad = {
natural_scroll = true;
disable_while_typing = true;
};
};
# General settings
general = {
gaps_in = 2;
gaps_out = 4;
border_size = 1;
"col.active_border" = "rgba(797979aa)";
"col.inactive_border" = "rgba(393939aa)";
layout = "dwindle";
};
# Decoration
decoration = {
rounding = 4;
blur.enabled = false;
};
# Animations
animations = {
enabled = false;
};
# Layout
dwindle = {
pseudotile = true;
preserve_split = true;
};
# Misc
misc = {
force_default_wallpaper = 0;
disable_hyprland_logo = true;
disable_splash_rendering = true;
};
# Key bindings
"$mainMod" = "SUPER";
bind = [
# Applications
"$mainMod, Return, exec, ${cfg.terminalCommand}"
"$mainMod, Space, exec, pkill wofi || wofi --show drun"
"$mainMod, q, killactive"
"$mainMod SHIFT, escape, exit"
"$mainMod SHIFT, q, exec, swaylock"
"$mainMod, f, togglefloating"
"$mainMod SHIFT, F, fullscreen"
"$mainMod, g, pseudo"
"$mainMod, t, togglesplit"
# Move focus with mainMod + hjkl
"$mainMod, h, movefocus, l"
"$mainMod, l, movefocus, r"
"$mainMod, k, movefocus, u"
"$mainMod, j, movefocus, d"
# Switch workspaces with mainMod + [0-9]
"$mainMod, 1, workspace, 1"
"$mainMod, n, workspace, 1"
"$mainMod, 2, workspace, 2"
"$mainMod, m, workspace, 2"
"$mainMod, 3, workspace, 3"
"$mainMod, comma, workspace, 3"
"$mainMod, 4, workspace, 4"
"$mainMod, period, workspace, 4"
"$mainMod, 5, workspace, 5"
"$mainMod, slash, workspace, 5"
"$mainMod, 6, workspace, 6"
"$mainMod, 7, workspace, 7"
"$mainMod, 8, workspace, 8"
"$mainMod, 9, workspace, 9"
"$mainMod, 0, workspace, 10"
# Window management (similar to your GNOME setup)
"$mainMod SHIFT, h, movewindow, l"
"$mainMod SHIFT, l, movewindow, r"
"$mainMod SHIFT, k, movewindow, u"
"$mainMod SHIFT, j, movewindow, d"
"$mainMod SHIFT, 1, movetoworkspacesilent, 1"
"$mainMod SHIFT, n, movetoworkspacesilent, 1"
"$mainMod SHIFT, 2, movetoworkspacesilent, 2"
"$mainMod SHIFT, m, movetoworkspacesilent, 2"
"$mainMod SHIFT, 3, movetoworkspacesilent, 3"
"$mainMod SHIFT, comma, movetoworkspacesilent, 3"
"$mainMod SHIFT, 4, movetoworkspacesilent, 4"
"$mainMod SHIFT, period, movetoworkspacesilent, 4"
"$mainMod SHIFT, 5, movetoworkspacesilent, 5"
"$mainMod SHIFT, slash, movetoworkspacesilent, 5"
"$mainMod SHIFT, 6, movetoworkspacesilent, 6"
"$mainMod SHIFT, 7, movetoworkspacesilent, 7"
"$mainMod SHIFT, 8, movetoworkspacesilent, 8"
"$mainMod SHIFT, 9, movetoworkspacesilent, 9"
"$mainMod SHIFT, 0, movetoworkspacesilent, 10"
# Screenshots
", Print, exec, grimblast copy area"
];
bindr = [
# overview
# "$mainMod, SUPER_L, overview:toggle" $ hyprspace plugin
"$mainMod SHIFT, R, exec, systemctl --user restart hyprpanel.service"
];
binde = [
# Move between workspaces
# "$mainMod, n, workspace, r+1"
# "$mainMod, p, workspace, r-1"
# Resize windows
"$mainMod CTRL, h, resizeactive, -40 0"
"$mainMod CTRL, l, resizeactive, 40 0"
"$mainMod CTRL, k, resizeactive, 0 -20"
"$mainMod CTRL, j, resizeactive, 0 20"
];
# Mouse bindings
bindm = [
"$mainMod, mouse:272, movewindow"
"$mainMod, mouse:273, resizewindow"
];
} cfg.extraOptions;
};
}

View file

@ -0,0 +1,22 @@
{
osConfig,
lib,
...
}:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
config = {
services.hyprpaper = {
enable = true;
settings = cfg.hyprpaperSettings;
};
};
}

View file

@ -0,0 +1,8 @@
{
...
}:
{
services.hyprpolkitagent = {
enable = true;
};
}

View file

@ -0,0 +1,93 @@
{
osConfig,
lib,
pkgs,
upkgs,
...
}:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
home.packages = with pkgs; [
upkgs.quickshell
pulseaudio
brightnessctl
networkmanager
bluez
bluez-tools
power-profiles-daemon
upower
systemd
hyprlock
];
# Ensure CLI quickshell can resolve modules when not using --config-path
home.sessionVariables = {
QML_IMPORT_PATH = "$HOME/.config/quickshell";
QML2_IMPORT_PATH = "$HOME/.config/quickshell";
};
# install config files
home.file = {
".config/quickshell/shell.qml".source = ./quickshell/shell.qml;
".config/quickshell/panels/TopBar.qml".source = ./quickshell/panels/TopBar.qml;
".config/quickshell/notifications/NotificationServer.qml".source =
./quickshell/notifications/NotificationServer.qml;
".config/quickshell/notifications/NotificationPopup.qml".source =
./quickshell/notifications/NotificationPopup.qml;
".config/quickshell/notifications/NotificationCenter.qml".source =
./quickshell/notifications/NotificationCenter.qml;
".config/quickshell/widgets/status/Workspaces.qml".source =
./quickshell/widgets/status/Workspaces.qml;
".config/quickshell/widgets/status/Clock.qml".source = ./quickshell/widgets/status/Clock.qml;
".config/quickshell/widgets/status/SystemTrayWidget.qml".source =
./quickshell/widgets/status/SystemTrayWidget.qml;
".config/quickshell/widgets/status/Battery.qml".source = ./quickshell/widgets/status/Battery.qml;
".config/quickshell/widgets/controls/QuickSettings.qml".source =
./quickshell/widgets/controls/QuickSettings.qml;
".config/quickshell/widgets/controls/Audio.qml".source = ./quickshell/widgets/controls/Audio.qml;
".config/quickshell/widgets/controls/Network.qml".source =
./quickshell/widgets/controls/Network.qml;
".config/quickshell/widgets/controls/Bluetooth.qml".source =
./quickshell/widgets/controls/Bluetooth.qml;
".config/quickshell/widgets/controls/Brightness.qml".source =
./quickshell/widgets/controls/Brightness.qml;
".config/quickshell/widgets/controls/PowerProfilesWidget.qml".source =
./quickshell/widgets/controls/PowerProfilesWidget.qml;
".config/quickshell/panels/qmldir".source = ./quickshell/panels/qmldir;
".config/quickshell/notifications/qmldir".source = ./quickshell/notifications/qmldir;
".config/quickshell/widgets/status/qmldir".source = ./quickshell/widgets/status/qmldir;
".config/quickshell/widgets/controls/qmldir".source = ./quickshell/widgets/controls/qmldir;
# optional: .qmlls.ini should be gitignored; create empty to enable LSP
".config/quickshell/.qmlls.ini".text = "";
};
systemd.user.services.quickshell = {
Unit = {
Description = "Quickshell Desktop Shell";
PartOf = [ "graphical-session.target" ];
After = [ "graphical-session.target" ];
};
Service = {
ExecStart = "${upkgs.quickshell}/bin/quickshell --config-path %h/.config/quickshell";
Restart = "on-failure";
RestartSec = 2;
Environment = [
"QML_IMPORT_PATH=%h/.config/quickshell"
"QT_QPA_PLATFORM=wayland"
# Ensure we find icons
"XDG_CURRENT_DESKTOP=quickshell"
];
};
Install = {
WantedBy = [ "graphical-session.target" ];
};
};
}

View file

@ -0,0 +1,10 @@
{ pkgs, ... }:
{
home.packages = with pkgs; [
(writeShellScriptBin "toggle-airplane-mode" (builtins.readFile ./scripts/toggle-airplane-mode.sh))
(writeShellScriptBin "toggle-power-profile" (builtins.readFile ./scripts/toggle-power-profile.sh))
(writeShellScriptBin "wofi-wifi-menu" (builtins.readFile ./scripts/wofi-wifi-menu.sh))
(writeShellScriptBin "wofi-bluetooth-menu" (builtins.readFile ./scripts/wofi-bluetooth-menu.sh))
(writeShellScriptBin "confirm-action" (builtins.readFile ./scripts/confirm-action.sh))
];
}

View file

@ -0,0 +1,14 @@
#!/usr/bin/env bash
COMMAND_TO_RUN="$1"
PROMPT_MESSAGE="$2"
if [ -z "$PROMPT_MESSAGE" ]; then
PROMPT_MESSAGE="Are you sure?"
fi
choice=$(echo -e "No\nYes" | wofi --dmenu --location center -p "$PROMPT_MESSAGE")
if [ "$choice" == "Yes" ]; then
eval "$COMMAND_TO_RUN"
fi

View file

@ -0,0 +1,6 @@
#!/usr/bin/env bash
if [ "$(nmcli radio all)" = "enabled" ]; then
nmcli radio all off
else
nmcli radio all on
fi

View file

@ -0,0 +1,6 @@
#!/usr/bin/env bash
if [ "$(powerprofilesctl get)" = "performance" ]; then
powerprofilesctl set balanced
else
powerprofilesctl set performance
fi

View file

@ -0,0 +1,21 @@
#!/usr/bin/env bash
devices=$(bluetoothctl devices | awk '{print $2, $3}')
if [ -z "$devices" ]; then
options="󰂲 Power On\n󰂬 Scan for devices"
else
options="$devices\n󰂲 Power Off\n󰂬 Scan for devices"
fi
chosen=$(echo -e "$options" | wofi --dmenu --location 3 --yoffset 40 --xoffset -20 -p "Bluetooth")
case "$chosen" in
"󰂲 Power On") bluetoothctl power on;;
"󰂲 Power Off") bluetoothctl power off;;
"󰂬 Scan for devices") bluetoothctl scan on;;
*)
mac=$(echo "$chosen" | awk '{print $1}')
bluetoothctl connect "$mac"
;;
esac

View file

@ -0,0 +1,24 @@
#!/usr/bin/env bash
# Get a list of available Wi-Fi networks
nets=$(nmcli --terse --fields SSID,SECURITY,BARS device wifi list | sed '/^--/d' | sed 's/\\:/__/g')
# Get the current connection status
connected_ssid=$(nmcli -t -f active,ssid dev wifi | egrep '^yes' | cut -d: -f2)
if [[ ! -z "$connected_ssid" ]]; then
toggle="󰖪 Toggle Wi-Fi Off"
else
toggle="󰖩 Toggle Wi-Fi On"
fi
# Present the menu to the user
chosen_network=$(echo -e "$toggle\n$nets" | wofi --dmenu --location 3 --yoffset 40 --xoffset -20 -p "Wi-Fi Networks")
# Perform an action based on the user's choice
if [ "$chosen_network" = "$toggle" ]; then
nmcli radio wifi $([ "$connected_ssid" = "" ] && echo "on" || echo "off")
elif [ ! -z "$chosen_network" ]; then
ssid=$(echo "$chosen_network" | sed 's/__/\\:/g' | awk -F' ' '{print $1}')
nmcli device wifi connect "$ssid"
fi

View file

@ -0,0 +1,17 @@
{
...
}:
{
programs.swaylock = {
enable = true;
settings = {
color = "#000000";
indicator-caps-lock = true;
indicator-idle-visible = true;
indicator-radius = 100;
indicator-thickness = 10;
font = "JetBrainsMono Nerd Font Regular";
font-size = 20;
};
};
}

View file

@ -0,0 +1,251 @@
{
lib,
osConfig,
...
}:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
"swaync"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
config = lib.mkIf cfg.enable {
services.swaync = {
enable = true;
settings = {
ignore = [
"com.spotify.Client"
];
positionX = "right";
positionY = "top";
layer = "overlay";
control-center-layer = "top";
layer-shell = true;
cssPriority = "application";
control-center-margin-top = 0;
control-center-margin-bottom = 0;
control-center-margin-right = 0;
control-center-margin-left = 0;
notification-2fa-action = true;
notification-inline-replies = false;
notification-icon-size = 64;
notification-body-image-height = 100;
notification-body-image-width = 200;
timeout = 10;
timeout-low = 5;
timeout-critical = 0;
control-center-width = 500;
control-center-height = 600;
notification-window-width = 500;
keyboard-shortcuts = true;
image-visibility = "when-available";
transition-time = 200;
hide-on-clear = false;
hide-on-action = true;
script-fail-notify = true;
widgets = [
"inhibitors"
"title"
"dnd"
"volume"
"backlight"
"mpris"
"buttons-grid#quick"
"notifications"
];
# Widget configurations
widget-config = {
inhibitors = {
text = "Inhibitors";
button-text = "Clear All";
clear-all-button = true;
};
title = {
text = "Notifications";
clear-all-button = true;
button-text = "Clear All";
};
dnd.text = "Do Not Disturb";
mpris = {
image-size = 96;
image-radius = 12;
};
volume = {
label = "󰕾";
show-per-app = true;
};
backlight = {
label = "󰃟";
device = "intel_backlight";
};
"buttons-grid#quick" = {
columns = 4; # adjust: 3/4/5
icon-size = 20; # tweak to taste
actions = [
# Power
{
label = "󰐥";
tooltip = "Shutdown";
command = "confirm-action 'systemctl poweroff' 'Shutdown?'";
}
{
label = "󰜉";
tooltip = "Reboot";
command = "confirm-action 'systemctl reboot' 'Reboot?'";
}
{
label = "󰍃";
tooltip = "Logout";
command = "confirm-action 'hyprctl dispatch exit' 'Logout?'";
}
];
};
};
};
# Custom CSS for the control center
style = ''
.control-center {
background: #1a1b26;
border: 2px solid #7dcae4;
border-radius: 12px;
}
.control-center-list {
background: transparent;
}
.control-center .notification-row:focus,
.control-center .notification-row:hover {
opacity: 1;
background: #24283b;
}
.notification {
border-radius: 8px;
margin: 6px 12px;
box-shadow: 0 0 0 1px rgba(125, 196, 228, 0.3), 0 1px 3px 1px rgba(0, 0, 0, 0.7), 0 2px 6px 2px rgba(0, 0, 0, 0.3);
padding: 0;
}
/* Widget styling */
.widget-title {
margin: 8px;
font-size: 1.5rem;
color: #c0caf5;
}
.widget-dnd {
margin: 8px;
font-size: 1.1rem;
color: #c0caf5;
}
.widget-dnd > switch {
font-size: initial;
border-radius: 8px;
background: #414868;
border: 1px solid #7dcae4;
}
.widget-dnd > switch:checked {
background: #7dcae4;
}
.widget-mpris {
color: #c0caf5;
background: #24283b;
padding: 8px;
margin: 8px;
border-radius: 8px;
}
.widget-mpris-player {
padding: 8px;
margin: 8px;
}
.widget-mpris-title {
font-weight: bold;
font-size: 1.25rem;
}
.widget-mpris-subtitle {
font-size: 1.1rem;
color: #9ece6a;
}
.widget-volume {
background: #24283b;
padding: 8px;
margin: 8px;
border-radius: 8px;
color: #c0caf5;
}
.widget-backlight {
background: #24283b;
padding: 8px;
margin: 8px;
border-radius: 8px;
color: #c0caf5;
}
.widget-menubar {
background: #24283b;
padding: 8px;
margin: 8px;
border-radius: 8px;
color: #c0caf5;
}
.widget-menubar .menu-item button {
background: #1f2335;
color: #c0caf5;
border-radius: 8px;
padding: 6px 10px;
margin: 4px;
border: 1px solid #2e3440;
font-family: "JetBrainsMonoNL Nerd Font";
}
.widget-menubar .menu-item button:hover {
background: #414868;
border-color: #7dcae4;
}
.topbar-buttons button {
border: none;
background: transparent;
color: #c0caf5;
font-size: 1.1rem;
border-radius: 8px;
margin: 0 4px;
padding: 8px;
}
.topbar-buttons button:hover {
background: #414868;
}
.topbar-buttons button:active {
background: #7dcae4;
color: #1a1b26;
}
'';
};
};
}

View file

@ -0,0 +1,18 @@
{
osConfig,
lib,
pkgs,
...
}:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
}

View file

@ -0,0 +1,32 @@
{
pkgs,
...
}:
{
home.pointerCursor = {
gtk.enable = true;
# x11.enable = true;
package = pkgs.bibata-cursors;
name = "Bibata-Modern-Classic";
size = 16;
};
# GTK theming
gtk = {
enable = true;
theme = {
package = pkgs.flat-remix-gtk;
name = "Flat-Remix-GTK-Grey-Darkest";
};
iconTheme = {
package = pkgs.adwaita-icon-theme;
name = "Adwaita";
};
font = {
name = "Sans";
size = 11;
};
};
}

View file

@ -0,0 +1,258 @@
{ lib, osConfig, ... }:
let
ccfg = import ../../../config.nix;
cfg_path = [
ccfg.custom_config_key
"desktopEnvironment"
"hyprland"
"waybar"
];
cfg = lib.attrsets.getAttrFromPath cfg_path osConfig;
in
{
config = lib.mkIf cfg.enable {
programs.waybar = {
enable = true;
systemd.enable = true;
settings = {
mainBar = {
layer = "top";
position = "top";
height = 28;
spacing = 6;
margin-top = 0;
margin-bottom = 0;
margin-left = 10;
margin-right = 10;
modules-left = [
"hyprland/workspaces"
];
modules-center = [
"clock"
"temperature"
"cpu"
"memory"
"disk"
];
modules-right = [
"battery"
"battery#bat2"
"pulseaudio"
"network"
"bluetooth"
"power-profiles-daemon"
"backlight"
"custom/notifications"
"tray"
"custom/power"
];
"hyprland/workspaces" = {
format = "{icon}";
format-icons = {
"1" = "";
"2" = "";
"3" = "";
"4" = "";
"5" = "";
"6" = "";
"7" = "";
"8" = "";
"9" = "";
"10" = "";
"11" = "";
"12" = "";
"13" = "";
"14" = "";
"15" = "";
"16" = "";
"17" = "";
"18" = "";
"19" = "";
"20" = "";
};
disable-scroll = false;
};
# CENTER
clock = {
format = "{:%b %d, %H:%M}";
tooltip-format = "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>";
};
temperature = {
thermal-zone = 2;
hwmon-path = "/sys/class/hwmon/hwmon2/temp1_input";
critical-threshold = 80;
format-critical = "󰔏 {temperatureC}°C";
format = "󰔏 {temperatureC}°C";
};
cpu = {
format = "󰻠 {usage}%";
tooltip = true;
on-click = "btop";
};
memory = {
format = "󰍛 {}%";
on-click = "btop";
};
disk = {
interval = 30;
format = "󰋊 {percentage_used}%";
path = "/";
on-click = "btop";
};
# RIGHT
"battery" = {
"states" = {
# "good"= 95;
"warning" = 30;
"critical" = 15;
};
"format" = "{capacity}% {icon}";
"format-full" = "{capacity}% {icon}";
"format-charging" = "{capacity}% ";
"format-plugged" = "{capacity}% ";
"format-alt" = "{time} {icon}";
# "format-good"= ""; // An empty format will hide the module
# "format-full"= "";
"format-icons" = [
""
""
""
""
""
];
};
"battery#bat2" = {
"bat" = "BAT2";
};
pulseaudio = {
format = "{icon} {volume}%";
format-bluetooth = "󰂰 {volume}%";
format-bluetooth-muted = "󰂲 ";
format-muted = "󰖁 ";
format-source = "󰍬 {volume}%";
format-source-muted = "󰍭 ";
format-icons = {
headphone = "󰋋";
hands-free = "󰂑";
headset = "󰂑";
phone = "󰏲";
portable = "󰦧";
car = "󰄋";
default = [
"󰕿"
"󰖀"
"󰕾"
];
};
scroll-step = 5;
on-click = "pavucontrol";
on-click-right = "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
};
network = {
format-wifi = "󰤨 {essid} ({signalStrength}%)";
format-ethernet = "󰈀 {ipaddr}/{cidr}";
tooltip-format = "{ifname} via {gwaddr} ";
format-linked = "󰈀 {ifname} (No IP)";
format-disconnected = "󰖪 Disconnected";
# on-click = "wofi-wifi-menu";
# on-click-right = "nmcli radio wifi toggle";
};
bluetooth = {
format = "󰂯 {status}";
format-connected = "󰂱 {device_alias}";
format-connected-battery = "󰂱 {device_alias} {device_battery_percentage}%";
tooltip-format = "{controller_alias}\t{controller_address}\n\n{num_connections} connected";
tooltip-format-connected = "{controller_alias}\t{controller_address}\n\n{num_connections} connected\n\n{device_enumerate}";
tooltip-format-enumerate-connected = "{device_alias}\t{device_address}";
tooltip-format-enumerate-connected-battery = "{device_alias}\t{device_address}\t{device_battery_percentage}%";
# on-click = "wofi-bluetooth-menu";
# on-click-right = "bluetoothctl power toggle";
};
"power-profiles-daemon" = {
format = "{icon}";
"tooltip-format" = "Power profile: {profile}\nDriver: {driver}";
tooltip = true;
"format-icons" = {
default = "";
performance = "";
balanced = "";
"power-saver" = "";
};
};
backlight = {
format = "{percent}% {icon}";
"format-icons" = [
""
""
""
""
""
""
""
""
""
];
};
"custom/notifications" = {
format = "{icon} {}";
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;
tooltip = false;
};
"sway/language" = {
format = "{}";
};
"tray" = {
"spacing" = 10;
};
"custom/power" = {
format = " ";
tooltip = false;
menu = "on-click";
"menu-file" = ./waybar/power_menu.xml;
"menu-actions" = {
shutdown = "shutdown 0";
reboot = "reboot";
logout = "loginctl terminate-session $(loginctl list-sessions | grep seat0 | awk '{print $1}')";
};
};
};
};
style = builtins.readFile ./waybar/waybar.css;
};
};
}

View file

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<object class="GtkMenu" id="menu">
<child>
<object class="GtkMenuItem" id="logout">
<property name="label">Logout</property>
</object>
</child>
<child>
<object class="GtkSeparatorMenuItem" id="delimiter1" />
</child>
<child>
<object class="GtkMenuItem" id="reboot">
<property name="label">Reboot</property>
</object>
</child>
<child>
<object class="GtkSeparatorMenuItem" id="delimiter2" />
</child>
<child>
<object class="GtkMenuItem" id="shutdown">
<property name="label">Shutdown</property>
</object>
</child>
</object>
</interface>

View file

@ -0,0 +1,102 @@
* {
/* `otf-font-awesome` is required to be installed for icons */
font-family: "JetBrainsMonoNL Nerd Font", FontAwesome, Roboto, Helvetica, Arial, sans-serif;
font-size: 14px;
border: none;
border-radius: 0;
min-height: 0;
color: #f1f1f1;
}
window#waybar {
background: transparent;
}
#workspaces button.focused,
#workspaces button.active {
background-color: rgba(220, 220, 220, 0.2);
}
#workspaces button.urgent {
background-color: rgba(214, 82, 82, 0.3);
}
button,
#clock,
#battery,
#cpu,
#memory,
#disk,
#temperature,
#backlight,
#network,
#pulseaudio,
#wireplumber,
#custom-media,
#custom-notifications,
#custom-power,
#tray,
#mode,
#idle_inhibitor,
#scratchpad,
#power-profiles-daemon,
#bluetooth,
#language,
#mpd {
padding: 0 5px;
color: #f1f1f1;
background-color: rgba(220, 220, 220, 0.1);
border-radius: 6px;
}
button:hover,
#clock:hover,
#battery:hover,
#cpu:hover,
#memory:hover,
#disk:hover,
#temperature:hover,
#backlight:hover,
#network:hover,
#pulseaudio:hover,
#wireplumber:hover,
#custom-media:hover,
#custom-notifications:hover,
#tray:hover,
#mode:hover,
#idle_inhibitor:hover,
#scratchpad:hover,
#power-profiles-daemon:hover,
#bluetooth:hover,
#language:hover,
#mpd:hover {
color: #f1f1f1;
background-color: rgba(220, 220, 220, 0.2);
border-radius: 6px;
}
#power-profiles-daemon {
padding-right: 15px;
}
#power-profiles-daemon.performance {
color: #fff7d6;
}
#power-profiles-daemon.balanced {
color: #d6efff;
}
#power-profiles-daemon.power-saver {
color:#dcffd6;
}
#tray>.passive {
-gtk-icon-effect: dim;
}
#tray>.needs-attention {
-gtk-icon-effect: highlight;
background-color: #eb4d4b;
}

View file

@ -0,0 +1,26 @@
{
...
}:
{
programs.wofi = {
enable = true;
settings = {
width = 500;
height = 600;
location = "bottom";
show = "drun";
prompt = "...";
filter_rate = 100;
allow_markup = true;
no_actions = true;
halign = "fill";
orientation = "vertical";
content_halign = "fill";
insensitive = true;
allow_images = true;
image_size = 40;
gtk_dark = true;
};
};
}