#!/bin/bash CHOICE=$(printf " Logout\n Restart\n Sleep\n Shutdown" \ | wofi --dmenu \ --prompt "Power:" \ --width 300 \ --height 220 \ --hide-scroll \ --no-actions \ --insensitive \ | awk '{print $NF}') case "$CHOICE" in Logout) niri msg action quit ;; Restart) systemctl reboot ;; Sleep) systemctl suspend-then-hibernate ;; Shutdown) systemctl poweroff ;; esac