about summary refs log tree commit diff
path: root/scripts/exit
blob: a657ac4493c42c8b849522fc720810691f32f441 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/bash
#
# a simple dmenu session script
#
###

DMENU='dmenu'
choice=$(echo -e "logout\nsuspend\nhibernate\nshutdown\nreboot" | $DMENU)

case "$choice" in
  logout) kill -9 -1 & ;;
  suspend) systemctl suspend & ;;
  hibernate) systemctl hibernate & ;;
  shutdown) systemctl poweroff & ;;
  reboot) systemctl reboot & ;;
esac