My Nix Infra
nix nixos
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

ez-cmd-dnd and dnd in waybar

ydcjeff 9da1ae9e 17b4a730

+30 -2
+12
bin/ez-cmd-dnd
··· 1 + #!/usr/bin/env bash 2 + 3 + if [[ $# -eq 0 ]]; then 4 + makoctl mode -t dnd >/dev/null 5 + pkill -RTMIN+8 waybar 6 + elif [[ "$1" == "waybar" ]]; then 7 + if makoctl mode | grep dnd >/dev/null; then 8 + echo '{"alt": "dnd"}' 9 + else 10 + echo '{"alt": "default"}' 11 + fi 12 + fi
+1 -1
bin/ez-cmd-palette
··· 27 27 *logout*) loginctl terminate-session "$XDG_SESSION_ID" ;; 28 28 *lock*) hyprlock ;; 29 29 *sleep*) loginctl lock-session ;; 30 - *dnd*) makoctl mode -t dnd ;; 30 + *dnd*) ez-cmd-dnd ;; 31 31 esac
+13 -1
config/waybar/config.jsonc
··· 6 6 "modules-center": ["clock"], 7 7 "modules-right": [ 8 8 "tray", 9 + "custom/noti", 9 10 "backlight", 10 11 "battery", 11 12 "bluetooth", ··· 71 72 "tray": { 72 73 "icon-size": 16, 73 74 "spacing": 16, 74 - } 75 + }, 76 + "custom/noti": { 77 + "format": "{icon}", 78 + "format-icons": { 79 + "dnd": "\udb80\udc9b", 80 + "default": "\udb80\udc9a", 81 + }, 82 + "on-click": "ez-cmd-dnd", 83 + "exec": "ez-cmd-dnd waybar", 84 + "return-type": "json", 85 + "signal": 8, 86 + }, 75 87 }
+4
modules/desktop.nix
··· 89 89 name = "ez-cmd-hwctl"; 90 90 text = builtins.readFile ../bin/ez-cmd-hwctl; 91 91 }) 92 + (pkgs.writeShellApplication { 93 + name = "ez-cmd-dnd"; 94 + text = builtins.readFile ../bin/ez-cmd-dnd; 95 + }) 92 96 adwaita-icon-theme 93 97 kdePackages.breeze-icons 94 98 ];